-
Notifications
You must be signed in to change notification settings - Fork 20
/
docker-compose.yaml
129 lines (127 loc) · 4.79 KB
/
docker-compose.yaml
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
version: "3.8"
services:
db:
container_name: marble-postgres
image: postgres:15
restart: always
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: ${PG_PASSWORD:-marble}
POSTGRES_DB: marble
PGDATA: /data/postgres
PGPORT: ${PG_PORT:-5432}
ports:
- ${PG_PORT:-5432}:${PG_PORT:-5432}
volumes:
- marble-db:/data/postgres
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres"]
interval: 2s
timeout: 1s
retries: 5
api:
container_name: marble-api
image: europe-west1-docker.pkg.dev/marble-infra/marble/marble-backend:v0.27.0
platform: linux/amd64
restart: always
depends_on:
- db
entrypoint: ["./app", "--server", "--migrations"]
healthcheck:
test: wget --no-verbose --tries=1 --spider http://localhost:${API_PORT:-8080}/liveness || exit 1
interval: 10s
timeout: 60s
retries: 1
start_period: 30s
ports:
- ${HOST_API_PORT:-8080}:${API_PORT:-8080}
volumes:
- marble-tempfiles:/tempFiles
# - ./local_shared:/shared # uncomment and adapt this line if you need to inject a service account key into the container
environment:
ENV: ${ENV:-}
PORT: ${API_PORT:-}
PG_HOSTNAME: ${PG_HOSTNAME:-}
PG_PORT: ${PG_PORT:-}
PG_USER: postgres
PG_PASSWORD: ${PG_PASSWORD:-}
AUTHENTICATION_JWT_SIGNING_KEY: ${AUTHENTICATION_JWT_SIGNING_KEY:-}
INGESTION_BUCKET_URL: ${INGESTION_BUCKET_URL:-}
CASE_MANAGER_BUCKET_URL: ${CASE_MANAGER_BUCKET_URL:-}
FIREBASE_AUTH_EMULATOR_HOST: ${FIREBASE_AUTH_EMULATOR_HOST_SERVER:-}
MARBLE_APP_HOST: ${MARBLE_APP_HOST:-localhost:${HOST_APP_PORT:-3000}}
# default value of GOOGLE_CLOUD_PROJECT must be kept if working with the emulator (and the emulator is running in the docker image below)
GOOGLE_CLOUD_PROJECT: ${GOOGLE_CLOUD_PROJECT:-test-project}
GOOGLE_APPLICATION_CREDENTIALS: ${GOOGLE_APPLICATION_CREDENTIALS:-}
REQUEST_LOGGING_LEVEL: ${REQUEST_LOGGING_LEVEL:-}
LOGGING_FORMAT: ${LOGGING_FORMAT:-}
CREATE_GLOBAL_ADMIN_EMAIL: ${CREATE_GLOBAL_ADMIN_EMAIL:-}
CREATE_ORG_NAME: ${CREATE_ORG_NAME:-}
CREATE_ORG_ADMIN_EMAIL: ${CREATE_ORG_ADMIN_EMAIL:-}
SEGMENT_WRITE_KEY: ${SEGMENT_WRITE_KEY_BACKEND:-UgkImFmHmBZAWh5fxIKBY3QtvlcBrhqQ}
METABASE_SITE_URL: ${METABASE_SITE_URL:-}
METABASE_JWT_SIGNING_KEY: ${METABASE_JWT_SIGNING_KEY:-}
METABASE_GLOBAL_DASHBOARD_ID: ${METABASE_GLOBAL_DASHBOARD_ID:-}
cron:
container_name: marble-api-cron
image: europe-west1-docker.pkg.dev/marble-infra/marble/marble-backend:v0.27.0
platform: linux/amd64
restart: always
depends_on:
- api
entrypoint: ["./app", "--worker"]
volumes:
- marble-tempfiles:/tempFiles
environment:
ENV: ${ENV:-}
PG_HOSTNAME: ${PG_HOSTNAME:-}
PG_PORT: ${PG_PORT:-}
PG_USER: postgres
PG_PASSWORD: ${PG_PASSWORD:-}
INGESTION_BUCKET_URL: ${INGESTION_BUCKET_URL:-}
REQUEST_LOGGING_LEVEL: ${REQUEST_LOGGING_LEVEL:-}
LOGGING_FORMAT: ${LOGGING_FORMAT:-}
app:
container_name: marble-app
image: europe-west1-docker.pkg.dev/marble-infra/marble/marble-frontend:v0.27.0
platform: linux/amd64
restart: always
depends_on:
- api
- firebase_auth
healthcheck:
test: curl --fail http://localhost:${APP_PORT:-8080}/healthcheck || exit 1
interval: 10s
timeout: 60s
retries: 1
start_period: 30s
ports:
- ${HOST_APP_PORT:-3000}:8080
environment:
ENV: ${ENV:-development}
LICENSE_KEY: ${LICENSE_KEY:-LICENSE_KEY}
NODE_ENV: ${NODE_ENV:-production}
SESSION_SECRET: ${SESSION_SECRET:-placeholder}
SESSION_MAX_AGE: ${SESSION_MAX_AGE:-43200}
MARBLE_API_DOMAIN_CLIENT: ${MARBLE_API_DOMAIN_CLIENT:-http://localhost:8080}
MARBLE_API_DOMAIN_SERVER: ${MARBLE_API_DOMAIN_SERVER:-http://api:8080}
MARBLE_APP_DOMAIN: ${MARBLE_APP_DOMAIN:-http://localhost:${HOST_APP_PORT:-8080}}
FIREBASE_AUTH_EMULATOR_HOST: ${FIREBASE_AUTH_EMULATOR_HOST_CLIENT:-}
FIREBASE_API_KEY: ${FIREBASE_API_KEY:-placeholder}
FIREBASE_AUTH_DOMAIN: ${FIREBASE_AUTH_DOMAIN:-placeholder}
FIREBASE_PROJECT_ID: ${GOOGLE_CLOUD_PROJECT:-placeholder}
FIREBASE_STORAGE_BUCKET: ${FIREBASE_STORAGE_BUCKET:-placeholder}
FIREBASE_MESSAGING_SENDER_ID: ${FIREBASE_MESSAGING_SENDER_ID:-placeholder}
FIREBASE_APP_ID: ${FIREBASE_APP_ID:-placeholder}
SEGMENT_WRITE_KEY: ${SEGMENT_WRITE_KEY:-hC8qrY2OLhUpl1Xycw523tbuClxlQR6u}
firebase_auth:
container_name: firebase-auth
image: europe-west1-docker.pkg.dev/marble-infra/marble/firebase-emulator:latest
restart: always
ports:
- ${FIREBASE_AUTH_EMULATOR_PORT:-9099}:9099
- 4000:4000
volumes:
marble-db:
driver: local
marble-tempfiles: