Files
kanban/deploy
Gahow Wang cd1e9e09e7 ops: ttyd web terminal sidecar behind nginx auth_request
- tmux-web-attach.sh: attach browser to one window via link-window into a
  private temp session (no session-group pollution); window-size smallest
  while attached so the browser never gets cut off; mouse on for natural
  wheel/touch scrolling; status bar off; destroy-unattached cleanup
- start-ttyd.sh: ttyd on 127.0.0.1:7681, base path /term, url-arg enabled,
  Tokyo Night theme, system mono stack, fontSize 14
- systemd user unit + install script registration
- nginx: /term/ proxied with websocket upgrade, gated by auth_request to
  the kanban cookie check; unauthenticated -> 302 /login

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-28 21:20:40 +08:00
..

Local Kanban Nginx

Current User-Mode HTTPS Proxy

This repo includes a user-mode Nginx config that does not require sudo:

nginx -c /home/gahow/projects/kanban/deploy/nginx.user-8443.conf \
  -p /home/gahow/projects/kanban/.nginx

It listens on:

https://gahow-pc.ipads-lab.se.sjtu.edu.cn:8443

It uses the self-signed certificate under deploy/certs/, so browsers will show a certificate warning unless the certificate is trusted locally.

Reload it with:

nginx -s reload \
  -c /home/gahow/projects/kanban/deploy/nginx.user-8443.conf \
  -p /home/gahow/projects/kanban/.nginx

Stop it with:

nginx -s stop \
  -c /home/gahow/projects/kanban/deploy/nginx.user-8443.conf \
  -p /home/gahow/projects/kanban/.nginx

Production 443 Proxy

For port 443, install deploy/nginx.local-kanban.conf into the system Nginx site directory and use a trusted certificate. The root domain serves the portal page, and individual apps keep their own ports:

sudo cp deploy/nginx.local-kanban.conf /etc/nginx/sites-available/local-kanban
sudo ln -sf /etc/nginx/sites-available/local-kanban /etc/nginx/sites-enabled/local-kanban
sudo nginx -t
sudo systemctl reload nginx

The install script intentionally does not bind port 80 by default, because another local service may already own it. Enable HTTP-to-HTTPS redirect only when port 80 is free:

KANBAN_ENABLE_HTTP_REDIRECT=1 ./scripts/install-nginx-system.sh

The Node app should run only on localhost behind Nginx:

KANBAN_HOST=127.0.0.1 \
KANBAN_PORT=5180 \
KANBAN_AUTH_SECURE_COOKIE=1 \
KANBAN_REQUIRE_HTTPS=1 \
npm start

Kanban is then normally reached through the user-mode HTTPS proxy on:

https://gahow-pc.ipads-lab.se.sjtu.edu.cn:8443/

Persistent User Services

Use the user-level systemd units when the service should stay up without an open shell:

./scripts/install-user-systemd.sh

This installs and starts:

local-kanban.service
local-kanban-nginx-8443.service

Check them with:

systemctl --user status local-kanban.service
systemctl --user status local-kanban-nginx-8443.service