-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.local.yml
68 lines (66 loc) · 2.01 KB
/
docker-compose.local.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
68
services:
database:
image: postgis/postgis:14-3.2
shm_size: '512m'
ports:
- "5409:5432"
environment:
POSTGRES_DB: omslagroute
POSTGRES_USER: omslagroute
POSTGRES_PASSWORD: insecure
volumes:
- pg_data:/var/lib/postgresql/data
omslagroute:
image: ${REGISTRY:-127.0.0.1:5001}/${REPOSITORY:-salmagundi/wonen-omslagroute}:${VERSION:-latest}
build:
dockerfile: Dockerfile
context: app
container_name: salmagundi_wonen_omslagroute
ports:
- "8088:8088"
environment:
- DJANGO_SETTINGS_MODULE=settings.settings
- DJANGO_SECRET_KEY=local
- DJANGO_DEBUG=True
- DJANGO_ALLOWED_HOSTS=0.0.0.0,localhost,omslagroute.local
- DJANGO_ROOT_URLCONF=web.urls
- DJANGO_STATIC_URL=/static/
- ADMIN_USERNAME=admin
- ADMIN_PASSWORD=insecure
- DATABASE_NAME=omslagroute
- DATABASE_USER=omslagroute
- DATABASE_PASSWORD=insecure
- DATABASE_HOST=database
- UWSGI_HTTP=0.0.0.0:8088
- UWSGI_MASTER=1
- UWSGI_STATIC_INDEX=index.html
- UWSGI_STATIC_MAP=/omslagroute/static=/static
- UWSGI_CALLABLE=application
- UWSGI_VACUUM=1
- UWSGI_STATIC_EXPIRES=/* 3600
- UWSGI_OFFLOAD_THREADS=1
- UWSGI_HARAKIRI=15
- UWSGI_DIE_ON_TERM=1
- UWSGI_ENABLE_THREADS=1
- UWSGI_MODULE=wsgi:application
volumes:
- ./app:/app
- ./media:/media
- ./app/deploy:/deploy
command: bash -c "
cd /app &&
npm install &&
npm rebuild node-sass &&
./node_modules/.bin/node-sass -o ./assets/bundles/ static_src/sass &&
./node_modules/.bin/webpack --config webpack.config.js &&
python ./manage.py collectstatic --noinput &&
python ./manage.py migrate --noinput &&
python ./manage.py initadmin --username [email protected] --password insecure &&
python ./manage.py runserver 0.0.0.0:8088 --settings settings.settings"
depends_on:
- database
networks:
default:
name: omslagroute
volumes:
pg_data: