-
-
Notifications
You must be signed in to change notification settings - Fork 322
/
docker-compose.yml
456 lines (442 loc) · 22.7 KB
/
docker-compose.yml
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
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
volumes:
lago_postgres_data:
lago_redis_data:
lago_storage_data:
services:
db:
image: postgres:14-alpine
container_name: lago-db
restart: unless-stopped
environment:
POSTGRES_DB: ${POSTGRES_DB:-lago}
POSTGRES_USER: ${POSTGRES_USER:-lago}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-changeme}
PGDATA: /data/postgres
PGPORT: ${POSTGRES_PORT:-5432}
POSTGRES_SCHEMA: public
volumes:
- lago_postgres_data:/data/postgres
ports:
- ${POSTGRES_PORT:-5432}:${POSTGRES_PORT:-5432}
redis:
image: redis:6-alpine
container_name: lago-redis
restart: unless-stopped
command: --port ${REDIS_PORT:-6379}
volumes:
- lago_redis_data:/data
ports:
- ${REDIS_PORT:-6379}:${REDIS_PORT:-6379}
api:
container_name: lago-api
image: getlago/api:v1.17.4
restart: unless-stopped
depends_on:
- db
- redis
command: ['./scripts/start.sh']
healthcheck:
test: curl -f http://localhost:3000/health || exit 1
interval: 10s
start_period: 30s
timeout: 60s
# uncomment for a potentially faster startup if you have docker --version > 25.0.0
# start_interval: 2s
environment:
- LAGO_API_URL=${LAGO_API_URL:-http://localhost:3000}
- DATABASE_URL=postgresql://${POSTGRES_USER:-lago}:${POSTGRES_PASSWORD:-changeme}@${POSTGRES_HOST:-db}:${POSTGRES_PORT:-5432}/${POSTGRES_DB:-lago}?search_path=${POSTGRES_SCHEMA:-public}
- REDIS_URL=redis://${REDIS_HOST:-redis}:${REDIS_PORT:-6379}
- REDIS_PASSWORD=${REDIS_PASSWORD}
- SECRET_KEY_BASE=${SECRET_KEY_BASE:-your-secret-key-base-hex-64}
- RAILS_ENV=production
- RAILS_LOG_TO_STDOUT=${LAGO_RAILS_STDOUT:-true}
- SENTRY_DSN=${SENTRY_DSN}
- LAGO_FRONT_URL=${LAGO_FRONT_URL:-http://localhost}
- RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
- LAGO_RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
- LAGO_SIDEKIQ_WEB=${LAGO_SIDEKIQ_WEB}
- LAGO_ENCRYPTION_PRIMARY_KEY=${LAGO_ENCRYPTION_PRIMARY_KEY:-your-encryption-primary-key}
- LAGO_ENCRYPTION_DETERMINISTIC_KEY=${LAGO_ENCRYPTION_DETERMINISTIC_KEY:-your-encryption-deterministic-key}
- LAGO_ENCRYPTION_KEY_DERIVATION_SALT=${LAGO_ENCRYPTION_KEY_DERIVATION_SALT:-your-encryption-derivation-salt}
- LAGO_USE_AWS_S3=${LAGO_USE_AWS_S3:-false}
- LAGO_AWS_S3_ACCESS_KEY_ID=${LAGO_AWS_S3_ACCESS_KEY_ID:-azerty123456}
- LAGO_AWS_S3_SECRET_ACCESS_KEY=${LAGO_AWS_S3_SECRET_ACCESS_KEY:-azerty123456}
- LAGO_AWS_S3_REGION=${LAGO_AWS_S3_REGION:-us-east-1}
- LAGO_AWS_S3_BUCKET=${LAGO_AWS_S3_BUCKET:-bucket}
- LAGO_AWS_S3_ENDPOINT=${LAGO_AWS_S3_ENDPOINT}
- LAGO_USE_GCS=${LAGO_USE_GCS:-false}
- LAGO_GCS_PROJECT=${LAGO_GCS_PROJECT:-}
- LAGO_GCS_BUCKET=${LAGO_GCS_BUCKET:-}
- LAGO_PDF_URL=${LAGO_PDF_URL:-http://pdf:3000}
- LAGO_REDIS_CACHE_URL=redis://${LAGO_REDIS_CACHE_HOST:-redis}:${LAGO_REDIS_CACHE_PORT:-6379}
- LAGO_REDIS_CACHE_PASSWORD=${LAGO_REDIS_CACHE_PASSWORD}
- LAGO_DISABLE_SEGMENT=${LAGO_DISABLE_SEGMENT}
- LAGO_DISABLE_WALLET_REFRESH=${LAGO_DISABLE_WALLET_REFRESH}
- LAGO_OAUTH_PROXY_URL=https://proxy.getlago.com
- LAGO_LICENSE=${LAGO_LICENSE:-}
- GOOGLE_AUTH_CLIENT_ID=${GOOGLE_AUTH_CLIENT_ID:-}
- GOOGLE_AUTH_CLIENT_SECRET=${GOOGLE_AUTH_CLIENT_SECRET:-}
- NANGO_SECRET_KEY=${NANGO_SECRET_KEY:-}
# - SIDEKIQ_EVENTS=true
# - SIDEKIQ_PDFS=true
# - SIDEKIQ_BILLING=true
# - SIDEKIQ_CLOCK=true
# - SIDEKIQ_WEBHOOK=true
volumes:
- lago_storage_data:/app/storage
# If using GCS, you need to put the credentials keyfile here
#- gcs_keyfile.json:/app/gcs_keyfile.json
ports:
- ${API_PORT:-3000}:3000
front:
container_name: lago-front
image: getlago/front:v1.17.4
restart: unless-stopped
# Use this command if you want to use SSL with Let's Encrypt
# command: "/bin/sh -c 'while :; do sleep 6h & wait $${!}; nginx -s reload; done & nginx -g \"daemon off;\"'"
depends_on:
api:
condition: service_healthy
environment:
- API_URL=${LAGO_API_URL:-http://localhost:3000}
- APP_ENV=${APP_ENV:-production}
- LAGO_DISABLE_SIGNUP=${LAGO_DISABLE_SIGNUP:-false}
- LAGO_OAUTH_PROXY_URL=https://proxy.getlago.com
- SENTRY_DSN=${SENTRY_DSN_FRONT}
- NANGO_SECRET_KEY=${NANGO_SECRET_KEY:-}
ports:
- ${FRONT_PORT:-80}:80
# - 443:443
# Using SSL with Let's Encrypt
# volumes:
# - ./extra/nginx-letsencrypt.conf:/etc/nginx/conf.d/default.conf
# - ./extra/certbot/conf:/etc/letsencrypt
# - ./extra/certbot/www:/var/www/certbot
# Using SSL with self signed certificates
# volumes:
# - ./extra/nginx-selfsigned.conf:/etc/nginx/conf.d/default.conf
# - ./extra/ssl/nginx-selfsigned.crt:/etc/ssl/certs/nginx-selfsigned.crt
# - ./extra/ssl/nginx-selfsigned.key:/etc/ssl/private/nginx-selfsigned.key
# - ./extra/ssl/dhparam.pem:/etc/ssl/certs/dhparam.pem
# Only used for SSL support with Let's Encrypt
# certbot:
# image: certbot/certbot
# entrypoint: "/bin/sh -c 'trap exit TERM; while :; do certbot renew; sleep 12h & wait $${!}; done;'"
# volumes:
# - ./extra/certbot/conf:/etc/letsencrypt
# - ./extra/certbot/www:/var/www/certbot
api-worker:
container_name: lago-worker
image: getlago/api:v1.17.4
restart: unless-stopped
depends_on:
api:
condition: service_healthy
command: ['./scripts/start.worker.sh']
healthcheck:
test: ['CMD-SHELL', 'bundle exec sidekiqmon | grep $(hostname) || exit 1']
environment:
- LAGO_API_URL=${LAGO_API_URL:-http://localhost:3000}
- DATABASE_URL=postgresql://${POSTGRES_USER:-lago}:${POSTGRES_PASSWORD:-changeme}@${POSTGRES_HOST:-db}:${POSTGRES_PORT:-5432}/${POSTGRES_DB:-lago}?search_path=${POSTGRES_SCHEMA:-public}
- REDIS_URL=redis://${REDIS_HOST:-redis}:${REDIS_PORT:-6379}
- REDIS_PASSWORD=${REDIS_PASSWORD}
- SECRET_KEY_BASE=${SECRET_KEY_BASE:-your-secret-key-base-hex-64}
- RAILS_ENV=production
- RAILS_LOG_TO_STDOUT=${LAGO_RAILS_STDOUT:-true}
- SENTRY_DSN=${SENTRY_DSN}
- LAGO_RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
- RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
- LAGO_ENCRYPTION_PRIMARY_KEY=${LAGO_ENCRYPTION_PRIMARY_KEY:-your-encryption-primary-key}
- LAGO_ENCRYPTION_DETERMINISTIC_KEY=${LAGO_ENCRYPTION_DETERMINISTIC_KEY:-your-encryption-deterministic-key}
- LAGO_ENCRYPTION_KEY_DERIVATION_SALT=${LAGO_ENCRYPTION_KEY_DERIVATION_SALT:-your-encryption-derivation-salt}
- LAGO_FRONT_URL=${LAGO_FRONT_URL:-http://localhost}
- LAGO_USE_AWS_S3=${LAGO_USE_AWS_S3:-false}
- LAGO_AWS_S3_ACCESS_KEY_ID=${LAGO_AWS_S3_ACCESS_KEY_ID:-azerty123456}
- LAGO_AWS_S3_SECRET_ACCESS_KEY=${LAGO_AWS_S3_SECRET_ACCESS_KEY:-azerty123456}
- LAGO_AWS_S3_REGION=${LAGO_AWS_S3_REGION:-us-east-1}
- LAGO_AWS_S3_BUCKET=${LAGO_AWS_S3_BUCKET:-bucket}
- LAGO_AWS_S3_ENDPOINT=${LAGO_AWS_S3_ENDPOINT}
- LAGO_USE_GCS=${LAGO_USE_GCS:-false}
- LAGO_GCS_PROJECT=${LAGO_GCS_PROJECT:-}
- LAGO_GCS_BUCKET=${LAGO_GCS_BUCKET:-}
- LAGO_PDF_URL=${LAGO_PDF_URL:-http://pdf:3000}
- LAGO_REDIS_CACHE_URL=redis://${LAGO_REDIS_CACHE_HOST:-redis}:${LAGO_REDIS_CACHE_PORT:-6379}
- LAGO_REDIS_CACHE_PASSWORD=${LAGO_REDIS_CACHE_PASSWORD}
- LAGO_DISABLE_SEGMENT=${LAGO_DISABLE_SEGMENT}
- LAGO_DISABLE_WALLET_REFRESH=${LAGO_DISABLE_WALLET_REFRESH}
- NANGO_SECRET_KEY=${NANGO_SECRET_KEY:-}
- LAGO_LICENSE=${LAGO_LICENSE:-}
# - SIDEKIQ_EVENTS=true
# - SIDEKIQ_PDFS=true
# - SIDEKIQ_BILLING=true
# - SIDEKIQ_CLOCK=true
# - SIDEKIQ_WEBHOOK=true
volumes:
- lago_storage_data:/app/storage
# You can uncomment this if you want to use a dedicated Sidekiq worker for the event ingestion.
# It is recommendend if you have a high usage of events to not impact the other Sidekiq Jobs.
#api-events-worker:
# container_name: lago-events-worker
# image: getlago/api:v1.17.4
# restart: unless-stopped
# depends_on:
# api:
# condition: service_healthy
# command: ["./scripts/start.events.worker.sh"]
# environment:
# - LAGO_API_URL=${LAGO_API_URL:-http://localhost:3000}
# - DATABASE_URL=postgresql://${POSTGRES_USER:-lago}:${POSTGRES_PASSWORD:-changeme}@${POSTGRES_HOST:-db}:${POSTGRES_PORT:-5432}/${POSTGRES_DB:-lago}?search_path=${POSTGRES_SCHEMA:-public}
# - REDIS_URL=redis://${REDIS_HOST:-redis}:${REDIS_PORT:-6379}
# - REDIS_PASSWORD=${REDIS_PASSWORD}
# - SECRET_KEY_BASE=${SECRET_KEY_BASE:-your-secret-key-base-hex-64}
# - RAILS_ENV=production
# - RAILS_LOG_TO_STDOUT=${LAGO_RAILS_STDOUT:-true}
# - SENTRY_DSN=${SENTRY_DSN}
# - LAGO_RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
# - RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
# - LAGO_ENCRYPTION_PRIMARY_KEY=${LAGO_ENCRYPTION_PRIMARY_KEY:-your-encryption-primary-key}
# - LAGO_ENCRYPTION_DETERMINISTIC_KEY=${LAGO_ENCRYPTION_DETERMINISTIC_KEY:-your-encryption-deterministic-key}
# - LAGO_ENCRYPTION_KEY_DERIVATION_SALT=${LAGO_ENCRYPTION_KEY_DERIVATION_SALT:-your-encryption-derivation-salt}
# - LAGO_FRONT_URL=${LAGO_FRONT_URL:-http://localhost}
# - LAGO_USE_AWS_S3=${LAGO_USE_AWS_S3:-false}
# - LAGO_AWS_S3_ACCESS_KEY_ID=${LAGO_AWS_S3_ACCESS_KEY_ID:-azerty123456}
# - LAGO_AWS_S3_SECRET_ACCESS_KEY=${LAGO_AWS_S3_SECRET_ACCESS_KEY:-azerty123456}
# - LAGO_AWS_S3_REGION=${LAGO_AWS_S3_REGION:-us-east-1}
# - LAGO_AWS_S3_BUCKET=${LAGO_AWS_S3_BUCKET:-bucket}
# - LAGO_AWS_S3_ENDPOINT=${LAGO_AWS_S3_ENDPOINT}
# - LAGO_USE_GCS=${LAGO_USE_GCS:-false}
# - LAGO_GCS_PROJECT=${LAGO_GCS_PROJECT:-}
# - LAGO_GCS_BUCKET=${LAGO_GCS_BUCKET:-}
# - LAGO_PDF_URL=${LAGO_PDF_URL:-http://pdf:3000}
# - LAGO_REDIS_CACHE_URL=redis://${LAGO_REDIS_CACHE_HOST:-redis}:${LAGO_REDIS_CACHE_PORT:-6379}
# - LAGO_REDIS_CACHE_PASSWORD=${LAGO_REDIS_CACHE_PASSWORD}
# - LAGO_DISABLE_SEGMENT=${LAGO_DISABLE_SEGMENT}
# - LAGO_DISABLE_WALLET_REFRESH=${LAGO_DISABLE_WALLET_REFRESH}
# - NANGO_SECRET_KEY=${NANGO_SECRET_KEY:-}
# - SIDEKIQ_EVENTS=true
# - SIDEKIQ_CLOCK=true
# - SIDEKIQ_WEBHOOK=true
# - LAGO_LICENSE=${LAGO_LICENSE:-}
# You can uncomment this if you want to use a dedicated Sidekiq worker for the invoices pdf creation.
# It is recommended if you have a high usage of invoices being created to not impact the other Sidekiq Jobs.
#api-pdfs-worker:
# container_name: lago-pdfs-worker
# image: getlago/api:v1.17.4
# restart: unless-stopped
# depends_on:
# api:
# condition: service_healthy
# command: ["./scripts/start.pdfs.worker.sh"]
# environment:
# - LAGO_API_URL=${LAGO_API_URL:-http://localhost:3000}
# - DATABASE_URL=postgresql://${POSTGRES_USER:-lago}:${POSTGRES_PASSWORD:-changeme}@${POSTGRES_HOST:-db}:${POSTGRES_PORT:-5432}/${POSTGRES_DB:-lago}?search_path=${POSTGRES_SCHEMA:-public}
# - REDIS_URL=redis://${REDIS_HOST:-redis}:${REDIS_PORT:-6379}
# - REDIS_PASSWORD=${REDIS_PASSWORD}
# - SECRET_KEY_BASE=${SECRET_KEY_BASE:-your-secret-key-base-hex-64}
# - RAILS_ENV=production
# - RAILS_LOG_TO_STDOUT=${LAGO_RAILS_STDOUT:-true}
# - SENTRY_DSN=${SENTRY_DSN}
# - LAGO_RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
# - RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
# - LAGO_ENCRYPTION_PRIMARY_KEY=${LAGO_ENCRYPTION_PRIMARY_KEY:-your-encryption-primary-key}
# - LAGO_ENCRYPTION_DETERMINISTIC_KEY=${LAGO_ENCRYPTION_DETERMINISTIC_KEY:-your-encryption-deterministic-key}
# - LAGO_ENCRYPTION_KEY_DERIVATION_SALT=${LAGO_ENCRYPTION_KEY_DERIVATION_SALT:-your-encryption-derivation-salt}
# - LAGO_FRONT_URL=${LAGO_FRONT_URL:-http://localhost}
# - LAGO_USE_AWS_S3=${LAGO_USE_AWS_S3:-false}
# - LAGO_AWS_S3_ACCESS_KEY_ID=${LAGO_AWS_S3_ACCESS_KEY_ID:-azerty123456}
# - LAGO_AWS_S3_SECRET_ACCESS_KEY=${LAGO_AWS_S3_SECRET_ACCESS_KEY:-azerty123456}
# - LAGO_AWS_S3_REGION=${LAGO_AWS_S3_REGION:-us-east-1}
# - LAGO_AWS_S3_BUCKET=${LAGO_AWS_S3_BUCKET:-bucket}
# - LAGO_AWS_S3_ENDPOINT=${LAGO_AWS_S3_ENDPOINT}
# - LAGO_USE_GCS=${LAGO_USE_GCS:-false}
# - LAGO_GCS_PROJECT=${LAGO_GCS_PROJECT:-}
# - LAGO_GCS_BUCKET=${LAGO_GCS_BUCKET:-}
# - LAGO_PDF_URL=${LAGO_PDF_URL:-http://pdf:3000}
# - LAGO_REDIS_CACHE_URL=redis://${LAGO_REDIS_CACHE_HOST:-redis}:${LAGO_REDIS_CACHE_PORT:-6379}
# - LAGO_REDIS_CACHE_PASSWORD=${LAGO_REDIS_CACHE_PASSWORD}
# - LAGO_DISABLE_SEGMENT=${LAGO_DISABLE_SEGMENT}
# - LAGO_DISABLE_WALLET_REFRESH=${LAGO_DISABLE_WALLET_REFRESH}
# - NANGO_SECRET_KEY=${NANGO_SECRET_KEY:-}
# - SIDEKIQ_PDFS=true
# - SIDEKIQ_CLOCK=true
# - SIDEKIQ_WEBHOOK=true
# - LAGO_LICENSE=${LAGO_LICENSE:-}
# You can uncomment this if you want to use a dedicated Sidekiq worker for the invoices creation.
# It is recommended if you have a high usage of invoices being created to not impact the other Sidekiq Jobs.
#api-billing-worker:
# container_name: lago-billing-worker
# image: getlago/api:v1.17.4
# restart: unless-stopped
# depends_on:
# api:
# condition: service_healthy
# command: ["./scripts/start.billing.worker.sh"]
# environment:
# - LAGO_API_URL=${LAGO_API_URL:-http://localhost:3000}
# - DATABASE_URL=postgresql://${POSTGRES_USER:-lago}:${POSTGRES_PASSWORD:-changeme}@${POSTGRES_HOST:-db}:${POSTGRES_PORT:-5432}/${POSTGRES_DB:-lago}?search_path=${POSTGRES_SCHEMA:-public}
# - REDIS_URL=redis://${REDIS_HOST:-redis}:${REDIS_PORT:-6379}
# - REDIS_PASSWORD=${REDIS_PASSWORD}
# - SECRET_KEY_BASE=${SECRET_KEY_BASE:-your-secret-key-base-hex-64}
# - RAILS_ENV=production
# - RAILS_LOG_TO_STDOUT=${LAGO_RAILS_STDOUT:-true}
# - SENTRY_DSN=${SENTRY_DSN}
# - LAGO_RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
# - RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
# - LAGO_ENCRYPTION_PRIMARY_KEY=${LAGO_ENCRYPTION_PRIMARY_KEY:-your-encryption-primary-key}
# - LAGO_ENCRYPTION_DETERMINISTIC_KEY=${LAGO_ENCRYPTION_DETERMINISTIC_KEY:-your-encryption-deterministic-key}
# - LAGO_ENCRYPTION_KEY_DERIVATION_SALT=${LAGO_ENCRYPTION_KEY_DERIVATION_SALT:-your-encryption-derivation-salt}
# - LAGO_FRONT_URL=${LAGO_FRONT_URL:-http://localhost}
# - LAGO_USE_AWS_S3=${LAGO_USE_AWS_S3:-false}
# - LAGO_AWS_S3_ACCESS_KEY_ID=${LAGO_AWS_S3_ACCESS_KEY_ID:-azerty123456}
# - LAGO_AWS_S3_SECRET_ACCESS_KEY=${LAGO_AWS_S3_SECRET_ACCESS_KEY:-azerty123456}
# - LAGO_AWS_S3_REGION=${LAGO_AWS_S3_REGION:-us-east-1}
# - LAGO_AWS_S3_BUCKET=${LAGO_AWS_S3_BUCKET:-bucket}
# - LAGO_AWS_S3_ENDPOINT=${LAGO_AWS_S3_ENDPOINT}
# - LAGO_USE_GCS=${LAGO_USE_GCS:-false}
# - LAGO_GCS_PROJECT=${LAGO_GCS_PROJECT:-}
# - LAGO_GCS_BUCKET=${LAGO_GCS_BUCKET:-}
# - LAGO_PDF_URL=${LAGO_PDF_URL:-http://pdf:3000}
# - LAGO_REDIS_CACHE_URL=redis://${LAGO_REDIS_CACHE_HOST:-redis}:${LAGO_REDIS_CACHE_PORT:-6379}
# - LAGO_REDIS_CACHE_PASSWORD=${LAGO_REDIS_CACHE_PASSWORD}
# - LAGO_DISABLE_SEGMENT=${LAGO_DISABLE_SEGMENT}
# - LAGO_DISABLE_WALLET_REFRESH=${LAGO_DISABLE_WALLET_REFRESH}
# - NANGO_SECRET_KEY=${NANGO_SECRET_KEY:-}
# - SIDEKIQ_PDFS=true
# - SIDEKIQ_BILLING=true
# - SIDEKIQ_CLOCK=true
# - SIDEKIQ_WEBHOOK=true
# - LAGO_LICENSE=${LAGO_LICENSE:-}
# You can uncomment this if you want to use a dedicated Sidekiq worker for the clock jobs.
#api-clock-worker:
# container_name: lago-clock-worker
# image: getlago/api:v1.17.2
# restart: unless-stopped
# depends_on:
# api:
# condition: service_healthy
# command: ["./scripts/start.clock.worker.sh"]
# environment:
# - LAGO_API_URL=${LAGO_API_URL:-http://localhost:3000}
# - DATABASE_URL=postgresql://${POSTGRES_USER:-lago}:${POSTGRES_PASSWORD:-changeme}@${POSTGRES_HOST:-db}:${POSTGRES_PORT:-5432}/${POSTGRES_DB:-lago}?search_path=${POSTGRES_SCHEMA:-public}
# - REDIS_URL=redis://${REDIS_HOST:-redis}:${REDIS_PORT:-6379}
# - REDIS_PASSWORD=${REDIS_PASSWORD}
# - SECRET_KEY_BASE=${SECRET_KEY_BASE:-your-secret-key-base-hex-64}
# - RAILS_ENV=production
# - RAILS_LOG_TO_STDOUT=${LAGO_RAILS_STDOUT:-true}
# - SENTRY_DSN=${SENTRY_DSN}
# - LAGO_RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
# - RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
# - LAGO_ENCRYPTION_PRIMARY_KEY=${LAGO_ENCRYPTION_PRIMARY_KEY:-your-encryption-primary-key}
# - LAGO_ENCRYPTION_DETERMINISTIC_KEY=${LAGO_ENCRYPTION_DETERMINISTIC_KEY:-your-encryption-deterministic-key}
# - LAGO_ENCRYPTION_KEY_DERIVATION_SALT=${LAGO_ENCRYPTION_KEY_DERIVATION_SALT:-your-encryption-derivation-salt}
# - LAGO_FRONT_URL=${LAGO_FRONT_URL:-http://localhost}
# - LAGO_USE_AWS_S3=${LAGO_USE_AWS_S3:-false}
# - LAGO_AWS_S3_ACCESS_KEY_ID=${LAGO_AWS_S3_ACCESS_KEY_ID:-azerty123456}
# - LAGO_AWS_S3_SECRET_ACCESS_KEY=${LAGO_AWS_S3_SECRET_ACCESS_KEY:-azerty123456}
# - LAGO_AWS_S3_REGION=${LAGO_AWS_S3_REGION:-us-east-1}
# - LAGO_AWS_S3_BUCKET=${LAGO_AWS_S3_BUCKET:-bucket}
# - LAGO_AWS_S3_ENDPOINT=${LAGO_AWS_S3_ENDPOINT}
# - LAGO_USE_GCS=${LAGO_USE_GCS:-false}
# - LAGO_GCS_PROJECT=${LAGO_GCS_PROJECT:-}
# - LAGO_GCS_BUCKET=${LAGO_GCS_BUCKET:-}
# - LAGO_PDF_URL=${LAGO_PDF_URL:-http://pdf:3000}
# - LAGO_REDIS_CACHE_URL=redis://${LAGO_REDIS_CACHE_HOST:-redis}:${LAGO_REDIS_CACHE_PORT:-6379}
# - LAGO_REDIS_CACHE_PASSWORD=${LAGO_REDIS_CACHE_PASSWORD}
# - LAGO_DISABLE_SEGMENT=${LAGO_DISABLE_SEGMENT}
# - LAGO_DISABLE_WALLET_REFRESH=${LAGO_DISABLE_WALLET_REFRESH}
# - NANGO_SECRET_KEY=${NANGO_SECRET_KEY:-}
# - SIDEKIQ_PDFS=true
# - SIDEKIQ_BILLING=true
# - SIDEKIQ_CLOCK=true
# - SIDEKIQ_WEBHOOK=true
# - LAGO_LICENSE=${LAGO_LICENSE:-}
# You can uncomment this if you want to use a dedicated Sidekiq worker for the webhook jobs.
#api-webhook-worker:
# container_name: lago-webhook-worker
# image: getlago/api:v1.17.2
# restart: unless-stopped
# depends_on:
# api:
# condition: service_healthy
# command: ["./scripts/start.webhook.worker.sh"]
# environment:
# - LAGO_API_URL=${LAGO_API_URL:-http://localhost:3000}
# - DATABASE_URL=postgresql://${POSTGRES_USER:-lago}:${POSTGRES_PASSWORD:-changeme}@${POSTGRES_HOST:-db}:${POSTGRES_PORT:-5432}/${POSTGRES_DB:-lago}?search_path=${POSTGRES_SCHEMA:-public}
# - REDIS_URL=redis://${REDIS_HOST:-redis}:${REDIS_PORT:-6379}
# - REDIS_PASSWORD=${REDIS_PASSWORD}
# - SECRET_KEY_BASE=${SECRET_KEY_BASE:-your-secret-key-base-hex-64}
# - RAILS_ENV=production
# - RAILS_LOG_TO_STDOUT=${LAGO_RAILS_STDOUT:-true}
# - SENTRY_DSN=${SENTRY_DSN}
# - LAGO_RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
# - RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
# - LAGO_ENCRYPTION_PRIMARY_KEY=${LAGO_ENCRYPTION_PRIMARY_KEY:-your-encryption-primary-key}
# - LAGO_ENCRYPTION_DETERMINISTIC_KEY=${LAGO_ENCRYPTION_DETERMINISTIC_KEY:-your-encryption-deterministic-key}
# - LAGO_ENCRYPTION_KEY_DERIVATION_SALT=${LAGO_ENCRYPTION_KEY_DERIVATION_SALT:-your-encryption-derivation-salt}
# - LAGO_FRONT_URL=${LAGO_FRONT_URL:-http://localhost}
# - LAGO_USE_AWS_S3=${LAGO_USE_AWS_S3:-false}
# - LAGO_AWS_S3_ACCESS_KEY_ID=${LAGO_AWS_S3_ACCESS_KEY_ID:-azerty123456}
# - LAGO_AWS_S3_SECRET_ACCESS_KEY=${LAGO_AWS_S3_SECRET_ACCESS_KEY:-azerty123456}
# - LAGO_AWS_S3_REGION=${LAGO_AWS_S3_REGION:-us-east-1}
# - LAGO_AWS_S3_BUCKET=${LAGO_AWS_S3_BUCKET:-bucket}
# - LAGO_AWS_S3_ENDPOINT=${LAGO_AWS_S3_ENDPOINT}
# - LAGO_USE_GCS=${LAGO_USE_GCS:-false}
# - LAGO_GCS_PROJECT=${LAGO_GCS_PROJECT:-}
# - LAGO_GCS_BUCKET=${LAGO_GCS_BUCKET:-}
# - LAGO_PDF_URL=${LAGO_PDF_URL:-http://pdf:3000}
# - LAGO_REDIS_CACHE_URL=redis://${LAGO_REDIS_CACHE_HOST:-redis}:${LAGO_REDIS_CACHE_PORT:-6379}
# - LAGO_REDIS_CACHE_PASSWORD=${LAGO_REDIS_CACHE_PASSWORD}
# - LAGO_DISABLE_SEGMENT=${LAGO_DISABLE_SEGMENT}
# - LAGO_DISABLE_WALLET_REFRESH=${LAGO_DISABLE_WALLET_REFRESH}
# - NANGO_SECRET_KEY=${NANGO_SECRET_KEY:-}
# - SIDEKIQ_PDFS=true
# - SIDEKIQ_BILLING=true
# - SIDEKIQ_CLOCK=true
# - SIDEKIQ_WEBHOOK=true
# - LAGO_LICENSE=${LAGO_LICENSE:-}
api-clock:
container_name: lago-clock
image: getlago/api:v1.17.4
restart: unless-stopped
depends_on:
api:
condition: service_healthy
command: ['./scripts/start.clock.sh']
environment:
- LAGO_API_URL=${LAGO_API_URL:-http://localhost:3000}
- DATABASE_URL=postgresql://${POSTGRES_USER:-lago}:${POSTGRES_PASSWORD:-changeme}@${POSTGRES_HOST:-db}:${POSTGRES_PORT:-5432}/${POSTGRES_DB:-lago}?search_path=${POSTGRES_SCHEMA:-public}
- REDIS_URL=redis://${REDIS_HOST:-redis}:${REDIS_PORT:-6379}
- REDIS_PASSWORD=${REDIS_PASSWORD}
- SECRET_KEY_BASE=${SECRET_KEY_BASE:-your-secret-key-base-hex-64}
- RAILS_ENV=production
- RAILS_LOG_TO_STDOUT=${LAGO_RAILS_STDOUT:-true}
- SENTRY_DSN=${SENTRY_DSN}
- LAGO_DISABLE_WALLET_REFRESH=${LAGO_DISABLE_WALLET_REFRESH}
- LAGO_REDIS_CACHE_URL=redis://${LAGO_REDIS_CACHE_HOST:-redis}:${LAGO_REDIS_CACHE_PORT:-6379}
- LAGO_RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
- RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
- LAGO_ENCRYPTION_PRIMARY_KEY=${LAGO_ENCRYPTION_PRIMARY_KEY:-your-encryption-primary-key}
- LAGO_ENCRYPTION_DETERMINISTIC_KEY=${LAGO_ENCRYPTION_DETERMINISTIC_KEY:-your-encryption-deterministic-key}
- LAGO_ENCRYPTION_KEY_DERIVATION_SALT=${LAGO_ENCRYPTION_KEY_DERIVATION_SALT:-your-encryption-derivation-salt}
- NANGO_SECRET_KEY=${NANGO_SECRET_KEY:-}
- LAGO_LICENSE=${LAGO_LICENSE:-}
# - SIDEKIQ_CLOCK=true
pdf:
image: getlago/lago-gotenberg:7.8.2
migrate:
container_name: lago-migrate
image: getlago/api:v1.13.1
depends_on:
- db
- redis
command: ['./scripts/start.migrate.sh']
volumes:
- lago_storage_data:/app/storage
environment:
- RAILS_ENV=production
- SECRET_KEY_BASE=${SECRET_KEY_BASE:-your-secret-key-base-hex-64}
- RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
- LAGO_RSA_PRIVATE_KEY=${LAGO_RSA_PRIVATE_KEY} # Should be base64 encoded
- DATABASE_URL=postgresql://${POSTGRES_USER:-lago}:${POSTGRES_PASSWORD:-changeme}@${POSTGRES_HOST:-db}:${POSTGRES_PORT:-5432}/${POSTGRES_DB:-lago}?search_path=${POSTGRES_SCHEMA:-public}
- REDIS_URL=redis://${REDIS_HOST:-redis}:${REDIS_PORT:-6379}
- REDIS_PASSWORD=${REDIS_PASSWORD}