forked from NodeBB/NodeBB
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
55 lines (54 loc) · 1.65 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
55
version: '3.8'
services:
nodebb:
build: .
restart: unless-stopped
ports:
- "4567:4567/tcp" # comment this out if you don't want to expose NodeBB to the host, or change the first number to any port you want
# uncomment if you want to use another container as a reverse proxy
# expose:
# - 4567
volumes:
- ./.docker/build:/usr/src/app/build
- ./.docker/public/uploads:/usr/src/app/public/uploads
- ./.docker:/opt/config
- ./install/docker/setup.json:/usr/src/app/setup.json
mongo:
image: "mongo:7-jammy"
restart: unless-stopped
expose:
- "27017"
environment:
MONGO_INITDB_ROOT_USERNAME: nodebb
MONGO_INITDB_ROOT_PASSWORD: nodebb
MONGO_INITDB_DATABASE: nodebb
volumes:
- ./.docker/database/mongo/config:/etc/mongo
- ./.docker/database/mongo/data:/data/db
- ./install/docker/mongodb-user-init.js:/docker-entrypoint-initdb.d/user-init.js
profiles:
- mongo
postgres:
image: postgres:16.1-alpine
restart: unless-stopped
expose:
- "5432"
environment:
POSTGRES_USER: nodebb
POSTGRES_PASSWORD: nodebb
POSTGRES_DB: nodebb
volumes:
- ./.docker/database/postgresql/data:/var/lib/postgresql/data
profiles:
- postgres
redis:
image: redis:7.2.3-alpine
restart: unless-stopped
command: ["redis-server", "--appendonly", "yes", "--loglevel", "warning"]
# command: ["redis-server", "--save", "60", "1", "--loglevel", "warning"] # uncomment if you want to use snapshotting instead of AOF
expose:
- "6379"
volumes:
- ./.docker/database/redis:/data
profiles:
- redis