-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
63 lines (59 loc) · 1.45 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
x-var:
- &POSTGRES_USER
postgres
- &POSTGRES_PASSWORD
default
- &POSTGRES_DATABASE
postgres
- &POSTGRES_HOST
database
x-defaults: &defaults
logging:
driver: "json-file"
options:
max-size: 10m
max-file: "3"
services:
database:
container_name: *POSTGRES_HOST
environment:
POSTGRES_USER: *POSTGRES_USER
POSTGRES_PASSWORD: *POSTGRES_PASSWORD
POSTGRES_DB: *POSTGRES_DATABASE
build:
context: database
dockerfile: Dockerfile
ports: [5432:5432]
volumes: ["/pgdata"]
healthcheck:
test: ["CMD", "pg_isready", "-U", *POSTGRES_USER]
interval: 5s
timeout: 10s
retries: 10
<<: *defaults
legacydb:
container_name: oracle
#build:
# context: legacydb
# dockerfile: Dockerfile
environment:
APP_USER_PASSWORD: default
APP_USER: THE
ORACLE_RANDOM_PASSWORD: yes
platform: "linux/amd64"
image: gvenzl/oracle-free:23.5-slim-faststart
ports: [1521:1521]
volumes: [/opt/oracle/oradata]
healthcheck:
test: [ "CMD-SHELL", "healthcheck.sh" ]
interval: 5s
timeout: 10s
retries: 10
<<: *defaults
legacyflyway:
container_name: flyway
image: flyway/flyway
command: -url=jdbc:oracle:thin:@legacydb:1521/FREEPDB1 -user=THE -password=default -connectRetries=60 migrate
volumes: [./legacy/src/test/resources/db/migration:/flyway/sql]
depends_on: [legacydb]
<<: *defaults