who_need_help/scripts/edge-up.sh
SimpleTest 87e6667e6a
Some checks are pending
Quality / full-local-gates (push) Waiting to run
Add isolated Caddy edge for production and staging
2026-07-21 03:34:37 +03:00

23 lines
503 B
Bash
Executable File

#!/usr/bin/env bash
set -euo pipefail
ROOT=$(CDPATH='' cd -- "$(dirname -- "$0")/.." && pwd)
env_file=${1:-"$ROOT/.env.edge"}
if [[ "$env_file" != /* ]]; then
env_file="$ROOT/$env_file"
fi
if [[ ! -f "$env_file" ]]; then
echo "Edge environment does not exist: $env_file" >&2
exit 1
fi
"$ROOT/scripts/validate-edge-env.sh" "$env_file"
exec docker compose \
--project-directory "$ROOT" \
--env-file "$env_file" \
--file "$ROOT/compose.edge.yaml" \
up -d --build --wait --remove-orphans