-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
54 lines (48 loc) · 1.3 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
version: '3.6'
services:
# API
api:
image: docker.pkg.github.com/landazuripaul/codenames/codenames-api:latest
volumes:
- ./packages/api/env/production.env:/usr/src/codenames/packages/api/env/production.env
expose:
- '4000'
networks:
codenames:
environment:
- NODE_ENV=production
# Redis
redis:
image: redis:alpine
command: redis-server --requirepass sOmE_sEcUrE_pAsS
networks:
codenames:
ports:
- '6379:6379'
volumes:
- redis-data:/bitnami/redis/data
# Mongodb
mongodb:
image: mongo:4
ports:
- '27017:27017'
environment:
- MONGO_INITDB_ROOT_USERNAME=init_user
- MONGO_INITDB_ROOT_PASSWORD=fkIh!72N#
volumes:
# Files placed in the docker-entrypoint-initdb.d
# will be executed in alphabetical order
- ./database/mongodb/credentials.js:/docker-entrypoint-initdb.d/a.js
- ./database/mongodb/init.js:/docker-entrypoint-initdb.d/b.js
# If there is already a db, previous scripts will be skipped
# and the following database will be mounted instead
- mongo-data:/data/db
# Frontend
frontend:
image: docker.pkg.github.com/landazuripaul/codenames/codenames-frontend:latest
volumes:
redis-data:
mongo-data:
networks:
codenames:
name: codenames