deploy(hub): serve the bilingual website alongside auth API

This commit is contained in:
Loki 2026-10-24 15:10:24 +02:00
parent 69d065e3a6
commit bc5157046e
Signed by: boba
GPG key ID: 253067914055423B
2 changed files with 24 additions and 1 deletions

View file

@ -28,3 +28,11 @@ Approved logo is the V connection mark. The Hub serves SVG and PNG; mail uses a
- Public `/v1/info` reports GitHub enabled; `/v1/auth/session` reports anonymous without a cookie. Live start endpoint returns 303 to GitHub with the configured callback, state, S256 PKCE and a Secure/HttpOnly/SameSite cookie.
- Workspace tests: 66 passed; all-target Clippy with `-D warnings`, formatting and dependency audit passed (zero vulnerabilities/warnings).
- Complete provider authorization/code exchange still requires an account owner's browser consent. Automated checks verify the local callback/session flow with an injected provider, not real user consent.
## Website update — 2026-10-24
- Separate `VNOX-Web` source commit `622f396364bb`; static release `622f396364bb-9b77c9dbd02c` served through `/opt/vnox-central/web/current`.
- Static files use 0644 permissions, directories 0755. Both approved SVG/PNG marks remain available for transactional email.
- `/` and `/account` serve the website. `/v1/`, `/health`, `/ready`, `/version` remain Hub proxy routes; authentication logging suppression is preserved.
- Nginx configuration validated before reload. Website CSP allows only self-hosted scripts/styles, the GitHub avatar origin for images, and same-origin API connections.
- Live Chromium checked desktop landing, anonymous account/GitHub link, mobile account overflow, stylesheet MIME, JavaScript console and API/logo responses. No browser errors were observed. No real user authorization was performed.

View file

@ -33,7 +33,9 @@ server {
proxy_connect_timeout 5s;
proxy_read_timeout 40s;
}
location / {
root /opt/vnox-central/web/current;
index index.html;
location ^~ /v1/ {
proxy_pass http://127.0.0.1:37623;
proxy_http_version 1.1;
proxy_set_header Host $host;
@ -43,4 +45,17 @@ server {
proxy_connect_timeout 5s;
proxy_read_timeout 30s;
}
location = /health { proxy_pass http://127.0.0.1:37623; }
location = /ready { proxy_pass http://127.0.0.1:37623; }
location = /version { proxy_pass http://127.0.0.1:37623; }
location / {
try_files $uri $uri/ /index.html;
add_header Cache-Control "no-store" always;
add_header X-Content-Type-Options nosniff always;
add_header Referrer-Policy no-referrer always;
add_header X-Frame-Options DENY always;
add_header Content-Security-Policy "default-src 'none'; script-src 'self'; style-src 'self'; img-src 'self' https://avatars.githubusercontent.com; connect-src 'self'; font-src 'self'; base-uri 'none'; form-action 'self'; frame-ancestors 'none'; object-src 'none'" always;
add_header Permissions-Policy "camera=(), microphone=(), geolocation=()" always;
}
}