Setup fly.io deployments

This commit is contained in:
Dominic Ferrando
2026-07-01 14:47:52 -04:00
parent 2454d68e24
commit ab6eb56814
16 changed files with 248 additions and 456 deletions
Executable
+32
View File
@@ -0,0 +1,32 @@
#!/usr/bin/env bash
set -euo pipefail
cd "$(dirname "$0")"
deploy_api() {
fly secrets import --config apps/api/fly.toml --stage < .env.production
fly deploy --config apps/api/fly.toml --dockerfile apps/api/Dockerfile
}
deploy_portal() {
fly secrets import --config apps/portal/fly.toml --stage < .env.production
fly deploy --config apps/portal/fly.toml --dockerfile apps/portal/Dockerfile
}
target="${1:-all}"
case "$target" in
api)
deploy_api
;;
portal)
deploy_portal
;;
all)
deploy_api
deploy_portal
;;
*)
echo "Usage: $0 [api|portal]" >&2
exit 1
;;
esac