Containerize Phase 1 bot: Docker deployment on the Spark
Add Dockerfile, docker-compose.yml, docker-entrypoint.sh, and .dockerignore so the bot runs detached and survives reboots, replacing the foreground venv run. The image is generic (no secrets/deployment specifics baked in): host networking reaches both Synapse and the Mac; .env, config.toml, and the SSH key are mounted read-only. The entrypoint is the container's environment seam (D4 analog of launch-claude.sh) — it generates ~/.ssh/config for the mac-bridge alias from config.toml [mac] (new hostname/user fields) so the bot's `ssh mac-bridge` stays unchanged. SSH key mounted not baked; first connect uses accept-new host trust. Proven live on the Spark: container connects to Synapse and real messages launched drivable sessions on the phone across 2 rooms via the full chain.
This commit is contained in:
@@ -10,6 +10,16 @@ user = "@matrix-bridge-bot:<your-domain>" # a dedicated bot Matrix account (not
|
||||
# Credentials (access token or password) come from the environment or a gitignored secret —
|
||||
# never commit them. The bot reads the homeserver URL + bot creds at startup.
|
||||
|
||||
# How the bot reaches the Mac (the proven Phase 0 seam). The bot runs on the Spark,
|
||||
# where `ssh_alias` resolves; `launcher` is the absolute path to gui-launch.sh on the Mac.
|
||||
[mac]
|
||||
ssh_alias = "mac-bridge"
|
||||
launcher = "/Users/macpro/Projects/<your-repo>/scripts/gui-launch.sh"
|
||||
# Container only: docker-entrypoint.sh generates ~/.ssh/config for `ssh_alias` from these.
|
||||
# (On a host with `ssh_alias` already in ~/.ssh/config these are ignored.)
|
||||
hostname = "10.0.0.0" # the Mac's address reachable from the Spark (e.g. WireGuard IP)
|
||||
user = "<mac-username>"
|
||||
|
||||
# One [[room]] block per project.
|
||||
# room_id — the internal Matrix room ID (starts with '!'), NOT the human alias (#name:domain)
|
||||
# repo_dir — an absolute path on the Mac (note: ~/Projects uses a capital P)
|
||||
|
||||
Reference in New Issue
Block a user