-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.dev.yml
More file actions
49 lines (44 loc) · 1.04 KB
/
docker-compose.dev.yml
File metadata and controls
49 lines (44 loc) · 1.04 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
version: "3.7"
services:
# Accessible at http://localhost:3000
frontend:
build:
context: .
dockerfile: Dockerfile.dev
restart: unless-stopped
env_file: .env
ports:
- "3000:8000"
depends_on:
- cms
volumes:
- ./src:/app
- ./src/node_modules # Mount node modules from built container
environment:
WAIT_HOSTS: cms:1337 # Wait for the CMS to start before launching frontend
# Accessible at http://localhost:1337
cms:
image: strapi/strapi
restart: unless-stopped
env_file: .env
environment:
DATABASE_USERNAME: ${MONGO_INITDB_ROOT_USERNAME}
DATABASE_PASSWORD: ${MONGO_INITDB_ROOT_PASSWORD}
volumes:
- ./STRAPI_APP_CONTENT:/srv/app
depends_on:
- db
ports:
- "1337:1337"
# Accessible at mongodb://username:password@localhost:27017
db:
image: mongo
restart: unless-stopped
env_file: .env
volumes:
- db-data-dev:/data/db
ports:
- "27017:27017"
volumes:
# Database persistence
db-data-dev: