forked from netbox-community/netbox-qrcode
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
48 lines (48 loc) · 1.18 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
---
version: '3'
services:
netbox:
build:
context: ../
dockerfile: develop/Dockerfile
command: >
sh -c "python manage.py migrate &&
python manage.py runserver 0.0.0.0:8000"
ports:
- '8000:8000'
depends_on:
- postgres
- redis
env_file:
- ./dev.env
volumes:
- ./configuration.py:/opt/netbox/netbox/netbox/configuration.py
- ../netbox_qrcode:/source/netbox_qrcode
tty: true
worker:
build:
context: ../
dockerfile: develop/Dockerfile
command: sh -c "python manage.py rqworker"
depends_on:
- netbox
env_file:
- ./dev.env
volumes:
- ./configuration.py:/opt/netbox/netbox/netbox/configuration.py
- ../netbox_qrcode:/source/netbox_qrcode
tty: true
postgres:
image: postgres:12
env_file: dev.env
volumes:
- pgdata_netbox_qrcode:/var/lib/postgresql/data
redis:
image: redis:5-alpine
command:
- sh
- -c # this is to evaluate the $REDIS_PASSWORD from the env
- redis-server --appendonly yes --requirepass $$REDIS_PASSWORD ## $$ because of docker-compose
env_file: ./dev.env
volumes:
pgdata_netbox_qrcode: