-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
81 lines (78 loc) · 2.66 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
version: "3.8"
services:
localstack:
container_name: "${LOCALSTACK_DOCKER_NAME:-localstack-main}"
image: localstack/localstack:3.1
ports:
- "127.0.0.1:4566:4566" # LocalStack Gateway
- "127.0.0.1:4510-4559:4510-4559" # external services port range
environment:
# LocalStack configuration: https://docs.localstack.cloud/references/configuration/
DEBUG: ${DEBUG:-0}
AWS_DEFAULT_REGION: eu-west-2
SERVICES: sqs, s3
volumes:
- "${LOCALSTACK_VOLUME_DIR:-./volume}:/var/lib/localstack"
- "/var/run/docker.sock:/var/run/docker.sock"
- "./localstack_bootstrap:/etc/localstack/init/ready.d/"
request-api:
build:
context: .
dockerfile: request-api/Dockerfile
args:
GIT_COMMIT: placeholder
environment:
PYTHONUNBUFFERED: 1
AWS_ENDPOINT_URL: http://localstack:4566
CELERY_BROKER_URL: sqs://ABCDEFGHIJKLMNOPQRST:ZYXK7NiynGlTogH8Nj+P9nlE73sq3@localstack:4566
AWS_DEFAULT_REGION: eu-west-2
AWS_ACCESS_KEY_ID: example
AWS_SECRET_ACCESS_KEY: example
SQS_QUEUE_NAME: request-queue
DATABASE_URL: postgresql://postgres:password@request-db/request_database
SENTRY_ENABLED: "false"
SENTRY_DSN: https://secret.sentry.url/here
SENTRY_ENVIRONMENT: docker-compose-local
SENTRY_TRACING_ENABLED: "true"
SENTRY_TRACING_SAMPLE_RATE: "0.50"
SENTRY_DEBUG: "true"
restart: on-failure
ports:
- "8000:8000"
request-db:
image: postgres:16.2-alpine
environment:
POSTGRES_PASSWORD: password
POSTGRES_DB: request_database
restart: on-failure
ports:
- "54320:5432"
request-processor:
build:
context: .
dockerfile: request-processor/Dockerfile
args:
GIT_COMMIT: placeholder
environment:
PYTHONUNBUFFERED: 1
AWS_ENDPOINT_URL: http://localstack:4566
AWS_DEFAULT_REGION: eu-west-2
AWS_ACCESS_KEY_ID: example
AWS_SECRET_ACCESS_KEY: example
# CELERY_BROKER_URL: sqs://@sqs.eu-west-2.amazonaws.com
CELERY_BROKER_URL: sqs://example:example@localstack:4566
CELERY_BROKER_REGION: eu-west-2
CELERY_BROKER_IS_SECURE: "false"
DATABASE_URL: postgresql://postgres:password@request-db/request_database
REQUEST_FILES_BUCKET_NAME: dluhc-data-platform-request-files-local
SENTRY_ENABLED: "false"
SENTRY_DSN: https://secret.sentry.url/here
SENTRY_ENVIRONMENT: docker-compose-local
SENTRY_TRACING_ENABLED: "true"
SENTRY_TRACING_SAMPLE_RATE: "0.50"
SENTRY_DEBUG: "true"
restart: on-failure
deploy:
replicas: 1
volumes:
- "./request-processor/docker_volume:/opt"