-
Notifications
You must be signed in to change notification settings - Fork 3
/
docker-compose.yml
60 lines (59 loc) · 1.45 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
version: '3.8'
services:
backend:
build:
context: ./restapi
dockerfile: Dockerfile
restart: always
environment:
- REDIS_DB_HOST=redis-server
- SQLALCHEMY_DATABASE_URI=postgresql://balihotproperty:123@postgres/balihotproperty
volumes:
- "./restapi:/app"
- "/app/migrations"
ports:
- "0.0.0.0:5001:5000"
depends_on:
- postgres
- pgadmin4
- redis-server
postgres:
image: "postgres"
restart: always
environment:
- TZ=Asia/Kuala_Lumpur
- POSTGRES_DB=balihotproperty
- POSTGRES_USER=balihotproperty
- POSTGRES_PASSWORD=123
pgbackups:
image: "prodrigestivill/postgres-backup-local"
restart: always
volumes:
- "./restapi/backups:/backups"
depends_on:
- postgres
environment:
- POSTGRES_HOST=postgres
- POSTGRES_DB=balihotproperty
- POSTGRES_USER=balihotproperty
- POSTGRES_PASSWORD=123
- POSTGRES_EXTRA_OPTS=-Z9 --schema=public --blobs
- SCHEDULE=@every 2h00m00s
- BACKUP_KEEP_DAYS=7
- BACKUP_KEEP_WEEKS=4
- BACKUP_KEEP_MONTHS=6
- HEALTHCHECK_PORT=80
pgadmin4:
image: "dpage/pgadmin4"
ports:
- "0.0.0.0:5437:80"
environment:
- PGADMIN_DEFAULT_EMAIL=oman@balihotproperty.com
- PGADMIN_DEFAULT_PASSWORD=123
redis-server:
image: "redis"
sysctls:
- net.core.somaxconn=511
networks:
default:
name: restapi_networks