|
|
@@ -27,7 +27,7 @@ what on it, how web traffic reaches an app, and how apps run.
|
|
|
| OS | openSUSE Leap 16.0 (kernel 6.12, systemd 257) |
|
|
|
| Web server | nginx 1.27 |
|
|
|
| TLS | Let's Encrypt via certbot 5.1 |
|
|
|
-| DNS | `monoaf.com` at Hover |
|
|
|
+| DNS | `monoexp.com` at Hover |
|
|
|
|
|
|
Provisioning, SSH hardening and the firewall: **manual setup by admin**.
|
|
|
DNS records are also added by hand at Hover, one per host, before anything
|
|
|
@@ -60,9 +60,9 @@ and permissions, and nobody needs sudo just to copy a file into place.
|
|
|
│ └── proxy.conf headers for reverse proxying
|
|
|
└── vhosts.d/ one file per host (root-owned)
|
|
|
├── 00-default.conf
|
|
|
- ├── git.monoaf.com.conf
|
|
|
- ├── gotest.monoaf.com.conf
|
|
|
- └── posts.monoaf.com.conf
|
|
|
+ ├── git.monoexp.com.conf
|
|
|
+ ├── gotest.monoexp.com.conf
|
|
|
+ └── posts.monoexp.com.conf
|
|
|
|
|
|
/etc/letsencrypt/live/<host>/ certificate and key per host
|
|
|
/etc/goapps/<name>.env per-app settings (PORT=...)
|
|
|
@@ -109,7 +109,7 @@ server { listen 80 default_server; listen [::]:80 default_server; return 444; }
|
|
|
server { listen 443 ssl default_server; listen [::]:443 ssl default_server; ssl_reject_handshake on; }
|
|
|
server {
|
|
|
listen 80; listen [::]:80;
|
|
|
- server_name .monoaf.com;
|
|
|
+ server_name .monoexp.com;
|
|
|
location /.well-known/acme-challenge/ { root /srv/www/acme; }
|
|
|
location / { return 301 https://$host$request_uri; }
|
|
|
}
|
|
|
@@ -119,7 +119,7 @@ server {
|
|
|
the connection without a response.
|
|
|
- On port 443, an unknown host has its TLS handshake refused, so the server
|
|
|
never shows a certificate for a name it doesn't serve.
|
|
|
-- Any `*.monoaf.com` host on port 80 serves ACME challenges from one shared
|
|
|
+- Any `*.monoexp.com` host on port 80 serves ACME challenges from one shared
|
|
|
folder and redirects everything else to HTTPS. A new host can get its
|
|
|
certificate before it has its own nginx file.
|
|
|
|
|
|
@@ -149,7 +149,7 @@ proxy_set_header Connection "upgrade";
|
|
|
## Certificates
|
|
|
|
|
|
Once the DNS record exists, a certificate is one command. The agent runs a
|
|
|
-small root-owned wrapper that accepts a single `*.monoaf.com` hostname:
|
|
|
+small root-owned wrapper that accepts a single `*.monoexp.com` hostname:
|
|
|
|
|
|
```sh
|
|
|
sudo /usr/local/sbin/issue-cert <host>
|