-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Expand file tree
/
Copy pathcompose.override.yaml
More file actions
143 lines (134 loc) · 4.27 KB
/
compose.override.yaml
File metadata and controls
143 lines (134 loc) · 4.27 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
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
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
# 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
- 127.0.0.1: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
- ${OL_MOUNT_DIR:-.}:/openlibrary
environment:
- LOCAL_DEV=true
depends_on:
- db
- infobase
fast_web:
build:
context: .
dockerfile: docker/Dockerfile.oldev
ports:
# Debugger
- 127.0.0.1:3001:3000
volumes:
# Persistent volume mount for generated css and js
- ol-build:/openlibrary/static/build
- ${OL_MOUNT_DIR:-.}:/openlibrary
environment:
- LOCAL_DEV=true
solr:
environment:
# See compose.yaml for docs
# For dev, autoSoftCommit is 1s, meaning edits will show up in search after 1s
# Keep SOLR_OPTS in sync with other instances of solr in compose files
- SOLR_OPTS=
-Dsolr.autoSoftCommit.maxTime=1000
-Dsolr.autoCommit.maxTime=120000
-Dsolr.max.booleanClauses=30000
-Dsolr.environment=dev
- LOCAL_DEV=true
volumes:
- ./docker/ol-local-solr-start.sh:/docker/ol-solr-start.sh:ro
ports:
- 8983:8983
# Run the wrapper script which handles schema migrations in dev mode
command: /docker/ol-solr-start.sh
solr-updater:
build:
context: .
dockerfile: docker/Dockerfile.oldev
environment:
- OL_SOLR_NEXT=true
volumes:
# Persistent volume mount for installed git submodules
- ol-vendor:/openlibrary/vendor
- ${OL_MOUNT_DIR:-.}:/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:
- ${OL_MOUNT_DIR:-.}:/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
- ol-postgres:/var/lib/postgresql/data
covers:
build:
context: .
dockerfile: docker/Dockerfile.oldev
ports:
- 7075:7075
volumes:
- ol-vendor:/openlibrary/vendor
- ${OL_MOUNT_DIR:-.}:/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
- ${OL_MOUNT_DIR:-.}:/openlibrary
depends_on:
- db
home:
image: "${OLIMAGE:-oldev:latest}"
build:
context: .
dockerfile: docker/Dockerfile.oldev
init: true # this is needed for docker sigints to work without modifying the many scripts within
command: docker/ol-home-start.sh
environment:
- LOCAL_DEV=true
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
- ${OL_MOUNT_DIR:-.}:/openlibrary
# For OSP download persistence across restarts
- solr-updater-data:/solr-updater-data
volumes:
ol-vendor:
ol-build:
ol-nodemodules:
ol-postgres: