-
Notifications
You must be signed in to change notification settings - Fork 26
/
docker-compose-local.yml
91 lines (88 loc) · 2.11 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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
version: '3.8'
networks:
indrz-net-dev:
volumes:
indrz-db-data:
geoserver-dev:
indrz-static:
indrz-media:
services:
indrz_db:
hostname: indrz_db
container_name: indrz_db
image: kartoza/postgis:15-3.3
volumes:
- indrz-db-data:/var/lib/postgresql
ports:
- 5432:5432
env_file:
.env
environment:
- ALLOW_IP_RANGE=0.0.0.0/0
restart: on-failure
networks:
- indrz-net-dev
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres"]
interval: 10s
timeout: 5s
retries: 5
indrz_api:
container_name: indrz_api
image: indrz/indrz_api_dev:latest
build:
context: ./indrz
dockerfile: ./devops/docker/local/indrz_api/Dockerfile
# command: bash -c "python manage.py migrate && python manage.py collectstatic --no-input --clear && python manage.py runserver 0.0.0.0:8000"
ports:
- 8000:8000
depends_on:
- indrz_db
volumes:
- ./indrz:/app
- ./data/media:/opt/data/media
- ./data/static:/opt/data/static
- ./data/logs:/opt/data/logs
restart: always
networks:
- indrz-net-dev
env_file:
- .env
# GEOSERVER
geoserver:
container_name: geoserver
image: indrz/geoserver:2.23.0
volumes:
- ./data/geoserver/data_dir:/opt/geoserver/data_dir
ports:
- 8080:8080
restart: on-failure
networks:
- indrz-net-dev
env_file:
- .env
depends_on:
indrz_db:
condition: service_healthy
healthcheck:
test: "curl --fail --silent --write-out 'HTTP CODE : %{http_code}\n' --output /dev/null -u ${GEOSERVER_ADMIN_USER}:'${GEOSERVER_ADMIN_PASSWORD}' http://localhost:8080/geoserver/rest/about/version.xml"
interval: 1m30s
timeout: 10s
retries: 3
#NGINX
nginx:
container_name: nginx
hostname: nginx
image: indrz/indrz_nginx_dev:latest
volumes:
- ./data/static:/opt/data/static
- ./data/media:/opt/data/media
ports:
- "80:80"
networks:
- indrz-net-dev
restart: always
env_file:
- .env
depends_on:
- indrz_api