forked from ethibox/awesome-stacks
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhabitica.yml
48 lines (42 loc) · 1.26 KB
/
habitica.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
# DOMAIN=example.com docker stack deploy -c habitica.yml habitica
x-habitica: &habitica
image: ethibox/habitica:${VERSION:-latest}
environment:
- ADMIN_EMAIL=${ADMIN_EMAIL:-noreply@example.com}
- BASE_URL=http://server:3000
- NODE_DB_URI=mongodb://mongo/habitrpg
services:
web:
<<: *habitica
command: npm run client:dev
deploy:
labels:
- traefik.enable=true
- traefik.http.routers.habitica-${NUMBER:-1}.rule=Host(`${DOMAIN:-habitica.localhost}`)
- traefik.http.routers.habitica-${NUMBER:-1}.entrypoints=${SCHEME:-https}
- traefik.http.routers.habitica-${NUMBER:-1}.service=habitica-${NUMBER:-1}
- traefik.http.routers.habitica-${NUMBER:-1}.tls.certresolver=letsencrypt
- traefik.http.services.habitica-${NUMBER:-1}.loadbalancer.server.port=8080
networks:
- traefik
- internal
server:
<<: *habitica
command: bash -c "cp config.json.example config.json && node ./website/transpiled-babel/index.js"
networks:
- internal
mongo:
image: mongo:4.0.3
volumes:
- ${VOLUME_PATH}mongo:/data/db
networks:
- internal
volumes:
mongo:
networks:
internal:
driver: overlay
attachable: true
traefik:
external: true
name: traefik-net