コンテンツにスキップ
#0094
DaemonContainers

A migration runner that disposes of itself

You're rolling out a schema change to 80 tenant containers. Each one needs a one-shot migration that runs once, exits, and leaves no trace. The old playbook leaves a migrate.sh lying around, half-disabled cron entries, scripts you find six months later and don't dare delete.

You POST to /api/v1/daemon/quick-start with the migration command and ttl: 600. The daemon spawns the process as an ephemeral program: not saved to programs.json, no boot persistence. The migration runs, exits, and after ten minutes the supervisord config is deleted automatically. Container reboot wipes it too.

You loop the POST across 80 tenant URLs. Forty minutes later they're all done, all gone, none of them tagged in the persistent state.

The migration runner doesn't need to be uninstalled. It uninstalls itself.