-
Notifications
You must be signed in to change notification settings - Fork 5
/
docker-compose.yml
67 lines (63 loc) · 1.9 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
56
57
58
59
60
61
62
63
64
65
66
67
version: "3.7"
# https://docs.docker.com/compose/compose-file/compose-file-v3/
services:
nginx:
image: nginx:alpine
# https://hub.docker.com/_/nginx
networks:
- inventree
volumes:
- static:/var/www/inventree/static
- media:/var/www/inventree/media
environment:
- NGINX_ENVSUBST_OUTPUT_DIR=/etc/nginx
# https://nginx.org/en/docs/ngx_core_module.html#worker_processes
- NGINX_WORKER_PROCESSES=auto
# https://nginx.org/en/docs/ngx_core_module.html#worker_rlimit_nofile
- NGINX_WORKER_RLIMIT_NOFILE=65535
# https://nginx.org/en/docs/ngx_core_module.html#worker_connections
- NGINX_WORKER_CONNECTIONS=65535
# https://nginx.org/en/docs/http/ngx_http_core_module.html#client_max_body_size
- NGINX_CLIENT_MAX_BODY_SIZE=10m
# https://nginx.org/en/docs/http/ngx_http_core_module.html#client_body_timeout
- NGINX_CLIENT_BODY_TIMEOUT=30s
- NGINX_HOST=inventree.yourdomain.test
mariadb:
image: mariadb:latest
# https://hub.docker.com/_/mariadb
environment:
- MYSQL_ROOT_PASSWORD=CHANGEME
- MYSQL_DATABASE=inventree
- MYSQL_USER=inventree
- MYSQL_PASSWORD=CHANGEME
networks:
- mariadb
volumes:
- mariadb:/var/lib/mysql
inventree:
image: zeigren/inventree:0.2.2
# https://hub.docker.com/r/zeigren/inventree
container_name: inventree
networks:
- inventree
- mariadb
volumes:
- static:/usr/src/static
- media:/usr/src/media
environment:
- DATABASE_PASSWORD=CHANGEME
- DATABASE_NAME=inventree
- DATABASE_USER=inventree
#- GUNICORN_WORKERS=2
# CREATE SUPERUSER ONCE THEN DELETE THESE
- CREATE_SUPERUSER=False
- DJANGO_SUPERUSER_USERNAME=admin
- DJANGO_SUPERUSER_EMAIL=admin@admin.com
- DJANGO_SUPERUSER_PASSWORD=admin
networks:
inventree:
mariadb:
volumes:
static:
media:
mariadb: