-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
/
compose.override.yaml
108 lines (100 loc) · 2.96 KB
/
compose.override.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
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
# This file is applied "on top" of compose.yaml when docker compose
# is used without the -f parameter. It contains local development specific
# configuration options which we don't want to apply to production/staging
services:
web:
build:
context: .
dockerfile: docker/Dockerfile.oldev
ports:
# Debugger
- 3000:3000
volumes:
# Persistent volume mount for installed git submodules
- ol-vendor:/openlibrary/vendor
# Persistent volume mount for generated css and js
- ol-build:/openlibrary/static/build
# Persistent volume mount for node_modules
- ol-nodemodules:/openlibrary/node_modules
# The above volume mounts are required so that the local dev bind mount below
# does not clobber the data generated inside the image / container
- .:/openlibrary
environment:
- LOCAL_DEV=true
depends_on:
- db
- infobase
solr:
ports:
- 8983:8983
solr-updater:
build:
context: .
dockerfile: docker/Dockerfile.oldev
environment:
- EXTRA_OPTS=--solr-next
volumes:
# Persistent volume mount for installed git submodules
- ol-vendor:/openlibrary/vendor
- .:/openlibrary
db:
image: postgres:${POSTGRES_VERSION:-9.3}
networks:
- dbnet
environment:
# This is okay for dev, but may need to be explored for prod
# This allows postgres access for psql user w/o password required
- POSTGRES_HOST_AUTH_METHOD=trust
volumes:
- .:/openlibrary
# Any files inside /docker-entrypoint-initdb.d/ will get run by postgres
# if the db is empty (which as of now is always, since we don't store the
# postgres data anywhere).
- ./docker/ol-db-init.sh:/docker-entrypoint-initdb.d/ol-db-init.sh
covers:
build:
context: .
dockerfile: docker/Dockerfile.oldev
ports:
- 7075:7075
volumes:
- ol-vendor:/openlibrary/vendor
- .:/openlibrary
infobase:
build:
context: .
dockerfile: docker/Dockerfile.oldev
# Commented out because not needed for most dev work, and 7000 conflicts
# with OS port on Mac. Uncomment if you need to test infobase directly.
# Mac users can do eg "7070:7000" to change the port used on the host
# machine to avoid conflicts.
# See https://github.com/internetarchive/openlibrary/issues/6315
# ports:
# - 7000:7000
volumes:
- ol-vendor:/openlibrary/vendor
- .:/openlibrary
depends_on:
- db
home:
image: "${OLIMAGE:-oldev:latest}"
build:
context: .
dockerfile: docker/Dockerfile.oldev
command: docker/ol-home-start.sh
networks:
- webnet
- dbnet
logging:
options:
max-size: "512m"
max-file: "4"
volumes:
- ol-vendor:/openlibrary/vendor
- ol-build:/openlibrary/static/build
- ol-nodemodules:/openlibrary/node_modules
- .:/openlibrary
volumes:
ol-vendor:
ol-build:
ol-nodemodules: