Expose only the console; node binds 8081 guest-internal
The console routes to nodes (rendezvous), so it is the single public port: server -> :8081 (no host forward), console -> :8080, 8090 forward dropped. Verified: node unreachable from host, routed workstream creation lands on turnstone-vm-main at 127.0.0.1:8081, route/command proxy works, cluster view tracks the workstream.
This commit is contained in:
1 parent
653532a72a
commit
a09b327ca9
4 files changed
+13
-15
No files matched your search
@@ -49,11 +49,10 @@ image, then packs it as `boco` qcow2 into the boco registry.
|
|||||||
scripts/run.sh
|
scripts/run.sh
|
||||||
```
|
```
|
||||||
|
|
||||||
- Web UI: <http://localhost:8080> (login `marvin` / `marvin-turnstone`
|
- Console (proxy to the node; chat UI + admin panel): :8080 — login
|
||||||
unless `ADMIN_PASSWORD` was overridden — change it)
|
`marvin` / `marvin-turnstone` unless `ADMIN_PASSWORD` was overridden.
|
||||||
- Console (admin panel + usage/verdicts/audit/settings): port 8090,
|
The node binds :8081 guest-internal only (no host forward); the
|
||||||
same login — shares the DB with the server, so workstreams, tools,
|
console routes to it, so all chat/admin goes through one port.
|
||||||
judges, policies, and settings are managed dynamically
|
|
||||||
- Ops SSH: `ssh -i configs/ssh/id_ed25519 -p 2222 marvin@localhost`
|
- Ops SSH: `ssh -i configs/ssh/id_ed25519 -p 2222 marvin@localhost`
|
||||||
- QEMU runs foreground; quit with `ctrl-a x`
|
- QEMU runs foreground; quit with `ctrl-a x`
|
||||||
|
|
||||||
|
|||||||
+2
-2
@@ -8,14 +8,14 @@
|
|||||||
# Prints a stable tailcat address (saved key at
|
# Prints a stable tailcat address (saved key at
|
||||||
# ~/.config/tailcat/keys/default.private.json). On the client machine:
|
# ~/.config/tailcat/keys/default.private.json). On the client machine:
|
||||||
#
|
#
|
||||||
# tailcat forward <tc-address> 8080:8080 8090:8090 2222:2222
|
# tailcat forward <tc-address> 8080:8080 2222:2222
|
||||||
#
|
#
|
||||||
# then browse http://localhost:8080 and ssh -p 2222 as usual.
|
# then browse http://localhost:8080 and ssh -p 2222 as usual.
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
cd "$(dirname "$0")/.."
|
cd "$(dirname "$0")/.."
|
||||||
|
|
||||||
TC="${TAILCAT_BIN:-$HOME/.local/bin/tailcat}"
|
TC="${TAILCAT_BIN:-$HOME/.local/bin/tailcat}"
|
||||||
PORTS="${TAILCAT_PORTS:-8080,8090,2222}"
|
PORTS="${TAILCAT_PORTS:-8080,2222}"
|
||||||
|
|
||||||
if ! command -v "$TC" >/dev/null 2>&1; then
|
if ! command -v "$TC" >/dev/null 2>&1; then
|
||||||
echo "tailcat not found at $TC" >&2
|
echo "tailcat not found at $TC" >&2
|
||||||
|
|||||||
+3
-4
@@ -1,9 +1,9 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
# Boot the turnstone VM (foreground; QEMU: ctrl-a x to quit).
|
# Boot the turnstone VM (foreground; QEMU: ctrl-a x to quit).
|
||||||
#
|
#
|
||||||
# Web UI: http://localhost:8080
|
# Console (proxy to the node; chat UI + admin): http://localhost:8080
|
||||||
# Web UI: http://localhost:8080
|
# (The node itself binds :8081 guest-internal — the console routes to
|
||||||
# Console: http://localhost:8090
|
# it; no direct host forward.)
|
||||||
# Ops SSH: ssh -i configs/ssh/id_ed25519 -p 2222 marvin@localhost
|
# Ops SSH: ssh -i configs/ssh/id_ed25519 -p 2222 marvin@localhost
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
cd "$(dirname "$0")/.."
|
cd "$(dirname "$0")/.."
|
||||||
@@ -14,7 +14,6 @@ exec boco boot marvin-turnstone \
|
|||||||
--memory "${VM_MEMORY:-4096M}" \
|
--memory "${VM_MEMORY:-4096M}" \
|
||||||
--mount-mode direct \
|
--mount-mode direct \
|
||||||
--forward "tcp:0.0.0.0:8080-:8080" \
|
--forward "tcp:0.0.0.0:8080-:8080" \
|
||||||
--forward "tcp:0.0.0.0:8090-:8090" \
|
|
||||||
--forward "tcp:0.0.0.0:2222-:22" \
|
--forward "tcp:0.0.0.0:2222-:22" \
|
||||||
--mount "$PWD/configs/turnstone:/home/marvin/.config/turnstone" \
|
--mount "$PWD/configs/turnstone:/home/marvin/.config/turnstone" \
|
||||||
--mount "$PWD/data:/var/lib/turnstone" \
|
--mount "$PWD/data:/var/lib/turnstone" \
|
||||||
|
|||||||
+4
-4
@@ -53,8 +53,8 @@ setpriv --reuid=marvin --regid=marvin --init-groups \
|
|||||||
# marvin — PID 1 stays the server, so if the server dies the VM halts.
|
# marvin — PID 1 stays the server, so if the server dies the VM halts.
|
||||||
# Shares the same config.toml/database as the server (WAL multi-writer).
|
# Shares the same config.toml/database as the server (WAL multi-writer).
|
||||||
setpriv --reuid=marvin --regid=marvin --init-groups \
|
setpriv --reuid=marvin --regid=marvin --init-groups \
|
||||||
/usr/local/bin/turnstone-console --host 0.0.0.0 --port 8090 &
|
/usr/local/bin/turnstone-console --host 0.0.0.0 --port 8080 &
|
||||||
echo "start-turnstone: console starting on :8090"
|
echo "start-turnstone: console starting on :8080"
|
||||||
|
|
||||||
# NOTE: turnstone reads $HOME/.config/turnstone/config.toml as marvin.
|
# NOTE: turnstone reads $HOME/.config/turnstone/config.toml as marvin.
|
||||||
#
|
#
|
||||||
@@ -67,6 +67,6 @@ echo "start-turnstone: console starting on :8090"
|
|||||||
# lands in the SSRF guard's never-allowed lane, which got the node
|
# lands in the SSRF guard's never-allowed lane, which got the node
|
||||||
# refused outright.
|
# refused outright.
|
||||||
export TURNSTONE_NODE_ID="${TURNSTONE_NODE_ID:-turnstone-vm-main}"
|
export TURNSTONE_NODE_ID="${TURNSTONE_NODE_ID:-turnstone-vm-main}"
|
||||||
export TURNSTONE_ADVERTISE_URL="${TURNSTONE_ADVERTISE_URL:-http://127.0.0.1:8080}"
|
export TURNSTONE_ADVERTISE_URL="${TURNSTONE_ADVERTISE_URL:-http://127.0.0.1:8081}"
|
||||||
exec setpriv --reuid=marvin --regid=marvin --init-groups \
|
exec setpriv --reuid=marvin --regid=marvin --init-groups \
|
||||||
/usr/local/bin/turnstone-server --host 0.0.0.0 --port 8080
|
/usr/local/bin/turnstone-server --host 0.0.0.0 --port 8081
|
||||||
Reference in new issue
Block a user