-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathdeploy.sh
More file actions
executable file
·42 lines (34 loc) · 1.13 KB
/
Copy pathdeploy.sh
File metadata and controls
executable file
·42 lines (34 loc) · 1.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#!/usr/bin/env bash
set -euo pipefail
ROOT_DIR="$(cd "$(dirname "$0")" && pwd)"
ENV_FILE="$ROOT_DIR/.env.deploy"
ENV_ARGS=()
if ! command -v docker >/dev/null 2>&1; then
printf 'Missing required command: docker\n' >&2
exit 1
fi
if ! docker compose version >/dev/null 2>&1; then
printf 'Docker Compose is required. Install a current Docker release and retry.\n' >&2
exit 1
fi
if ! docker info >/dev/null 2>&1; then
printf 'Docker is installed but the Docker daemon is not running.\n' >&2
exit 1
fi
if [ -f "$ENV_FILE" ]; then
ENV_ARGS=(--env-file "$ENV_FILE")
set -a
# shellcheck disable=SC1090
source "$ENV_FILE"
set +a
fi
cd "$ROOT_DIR"
docker compose "${ENV_ARGS[@]}" up --build -d
printf '\nDeployment started. Waiting for the application to become ready.\n'
"$ROOT_DIR/verify-deployment.sh"
printf '\nDeployment is ready.\n'
printf 'Enterprise: http://localhost:3000/enterprise/dashboard\n'
printf 'Personal: http://localhost:5173/#/ai-assistant\n'
printf 'Mobile: http://localhost:5174/#/register\n'
printf 'Governance: http://localhost:8000/#/en/cockpit\n'
printf 'API docs: http://localhost:3001/api/docs\n'