-
Notifications
You must be signed in to change notification settings - Fork 16
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
50 lines (48 loc) · 1.33 KB
/
docker-compose.yml
File metadata and controls
50 lines (48 loc) · 1.33 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
43
44
45
46
47
48
49
50
version: "3.8"
services:
ws:
image: realstraw/sbt:jdk11
working_dir: /orchard/ws
volumes:
- ./:/orchard/ws
environment:
AWS_ACCESS_KEY_ID: "${AWS_ACCESS_KEY_ID}"
AWS_SECRET_ACCESS_KEY: "${AWS_SECRET_ACCESS_KEY}"
AWS_SESSION_TOKEN: "${AWS_SESSION_TOKEN}"
AWS_REGION: "${ORCHARD_AWS_REGION}"
ORCHARD_AWS_LOGGING_URI: "${ORCHARD_AWS_LOGGING_URI}"
ORCHARD_PG_SECRET: "${ORCHARD_PG_SECRET}"
# set JVM_OPTS since realstraw/sbt:jdk11 is using GraalVM
JVM_OPTS: "-XX:+UnlockExperimentalVMOptions -XX:-UseJVMCICompiler"
ports:
- 9001:9000
# use tty instead of command for easier debugging
tty: true
# command:
# sbt orchardWS/run
db:
image: postgres:17
volumes:
- orchard-postgres-data:/var/lib/postgresql/data
environment:
POSTGRES_PASSWORD: "${ORCHARD_PG_SECRET}"
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres"]
interval: 5s
timeout: 5s
retries: 5
flyway:
image: flyway/flyway
volumes:
- ./flyway/sql:/flyway/sql
environment:
FLYWAY_URL: "jdbc:postgresql://db:5432/postgres"
FLYWAY_USER: "postgres"
FLYWAY_PASSWORD: "${ORCHARD_PG_SECRET}"
depends_on:
db:
condition: service_healthy
command:
migrate
volumes:
orchard-postgres-data: