Repository navigation
deploy: run ftwcloudd at cloud.ftw.energy in Stockholm - #2
Conversation
bootstrap.sh brings up an Amazon Linux 2023 host through SSM: swap, core dumps and sshd off, Docker as on the relay host, and ftw-cloud-deploy, which builds the checked-out commit and starts a new container. The service key is made on the host and copied to tmpfs before Docker starts. deploy/README.md records the running host: ids, how to update, check and tear it down, and the cost. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
💡 Codex ReviewLines 119 to 121 in a79d84e When an update produces an image whose process exits after startup, ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
A reboot test showed sshd listening on 22 again: cloud-init.service wants it, so disabling the unit is not enough. Masking it keeps it off across reboots. The security group already dropped 22. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ftwclouddnow runs athttps://cloud.ftw.energyon onet4g.smallin eu-north-1 (Stockholm). Fredrik asked for this on 13 Oct 2026. No box sends to it yet. That needs a Core built from srcfl/ftw#1595 and a separate decision by the owner.This PR records the running host.
deploy/bootstrap.shbuilds the host, anddeploy/README.mdholds the ids, how to update, check and tear it down, and the cost.What runs
976075258475(shared for now), eu-north-1a, default VPCi-0ecac4cbc6b5f8adc,t4g.small, AL2023 arm64, IMDSv2 required, no key pairvol-0760cad0e8551e5e4, 20 GB gp3, encrypted13.50.84.149(eipalloc-0085f3e68b6f36da4)sg-098992ad382ecf94a: 443/tcp in, nothing elseftw-cloud-host:AmazonSSMManagedInstanceCoreonlycloud.ftw.energyA, grey cloudmainatd8d3275, imageftw-cloud:d8d32752ff2dEvery resource carries the tag
Project=ftw-cloud. The cost is about $18 a month: $12.56 for the instance, $1.67 for the disk and $3.65 for the public IPv4 address.Where this differs from the ADR and the old deploy notes
ftwcloudd keygenmade the key on the host. It rests on the encrypted disk, readable by root only, and is copied to tmpfs before Docker starts. Move it to Secrets Manager before a Core release carries its public half.compose.ymlnames an image and has nobuild:.ftw-cloud-deploybuilds the checked-out commit, tags itftw-cloud:<12 hex>and writes that tag to/etc/ftw-cloud/compose.env. Images built in CI and deployed by digest come later.Checked from outside
The full scan overlapped the first reboot by about 20 seconds. The security group lets in 443 and nothing else, so the result does not depend on the host.
On the host, through SSM, these all held:
ss -ltnshows only0.0.0.0:443,[::]:443and one loopback port. Amazon Linux startssshd, andcloud-init.servicewants it at every boot, sobootstrap.shmasks it. Disabling it was not enough.kernel.core_pattern = |/bin/false.nonroot, with a read-only root file system,cap_drop ALLand core size 0 in/proc/<pid>/limits.root:root 600, and its copy in/run(tmpfs) is65532 400.BG6EvBxFzSHPVsQOES6PYaKFo5vHQmte9lJ6D5OBIT9JgcBrJAOxAucdqKXxS76pToQ7orI1Ivsno0OtxbMuliQ.Reboot test
I rebooted the instance twice from outside (
aws ec2 reboot-instances):/healthzstopped answering and was back at200 okabout 20 seconds after each reboot, with no one logging in.ftw-cloud-key.servicecopied the key to tmpfs, and the container started withrestarts=0and imageftw-cloud:d8d32752ff2d.CN=cloud.ftw.energy, Let's Encrypt YE2, valid to 11 Jan 2027,Verify return code: 0 (ok), TLS 1.3.sshdback on 22, which led to the mask. After the second rebootsshdis inactive,ss -ltnshows only 443 outward, andnc -z 13.50.84.149 22fails.🤖 Generated with Claude Code