-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathcompose.yaml
50 lines (48 loc) · 1.43 KB
/
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
services:
app:
build:
context: ./
dockerfile: Dockerfile
args:
- BUNDLE_GEMS__CONTRIBSYS__COM
environment:
- RAILS_LOG_TO_STDOUT=true
- POSTGRES_HOST=db
- REDIS_URL=redis:6379
- RAILS_ENV=development
- BUNDLE_GEMS__CONTRIBSYS__COM="${BUNDLE_GEMS__CONTRIBSYS__COM}"
volumes:
- .:/app
- ./tmp/pids:/app/tmp/pids
ports:
- "3000:3000"
depends_on:
- db
- redis
db:
image: postgres:12
ports:
- 5432:5432
environment:
- POSTGRES_PASSWORD=sekret
volumes:
- postgres-data:/var/lib/postgresql/data
redis:
image: redis:7
command: redis-server
ports:
- 6379:6379
volumes:
- redis:/data
gen_er_diagram:
image: schemacrawler/schemacrawler
entrypoint: /bin/bash
# https://www.schemacrawler.com/diagramming.html
# https://www.schemacrawler.com/docker-image.html
# https://hub.docker.com/r/schemacrawler/schemacrawler/
command: /opt/schemacrawler/bin/schemacrawler.sh --server=postgresql --host=db --database=development --user=postgres --password=sekret --info-level=standard --command=schema --output-format=svg --output-file=/var/preservation_catalog/db/schema_er_diagram.svg --config-file=/var/preservation_catalog/db/schemacrawler.config.properties --title "PresCat Schema ER Diagram"
volumes:
- ./db:/var/preservation_catalog/db
volumes:
redis:
postgres-data: