-
Notifications
You must be signed in to change notification settings - Fork 2
/
docker-compose.yml
111 lines (111 loc) · 2.37 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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
version: '2'
services:
app:
image: 'milanpasa/phapi'
build:
context: .
dockerfile: docker/Dockerfile
container_name: phapi_container
restart: always
ports:
- '${APP_UNSECURED_PORT}:80'
- '${APP_PORT}:443'
volumes:
- '.:/app'
- './certs/localhost:/certs'
networks:
- network
depends_on:
- db
env_file:
- ./.env
db:
image: 'mysql:5.7.22'
container_name: phapi_db_container
restart: always
ports:
- '${DB_PORT}:3306'
environment:
MYSQL_DATABASE: ${DB_NAME}
MYSQL_ROOT_PASSWORD: ${DB_PASSWORD}
volumes:
- 'db_data:/var/lib/mysql/'
networks:
- network
env_file:
- ./.env
rtt_db: # responseTimeTracking db [optional]
image: 'mysql:5.7.22'
container_name: rtt_db_container
restart: always
ports:
- '${RTT_DB_PORT}:3306'
environment:
MYSQL_DATABASE: ${RTT_DB_NAME}
MYSQL_ROOT_PASSWORD: ${RTT_DB_PASSWORD}
volumes:
- 'rtt_db_data:/var/lib/mysql/'
networks:
- network
env_file:
- ./.env
portainer:
image: portainer/portainer
container_name: phapi_portainer_container
restart: always
volumes:
- '/var/run/docker.sock:/var/run/docker.sock'
- 'portainer_data:/data'
ports:
- '${PORTAINER_PORT}:9000'
networks:
- network
env_file:
- ./.env
adminer:
image: adminer
container_name: phapi_adminer_container
restart: always
ports:
- '${ADMINER_PORT}:8080'
networks:
- network
env_file:
- ./.env
redis:
image: redis:7.0.4-alpine
container_name: phapi_redis_container
restart: always
command: 'redis-server --save 20 1 --loglevel warning --requirepass ${REDIS_PASS}'
volumes:
- phapi_redis_cache:/data
networks:
- network
redis-commander:
image: rediscommander/redis-commander:latest
restart: always
environment:
REDIS_HOSTS: redis
REDIS_HOST: redis
REDIS_PORT: redis:6379
REDIS_PASSWORD: ${REDIS_PASS}
HTTP_USER: admin
HTTP_PASSWORD: voldemort
networks:
- network
networks:
network:
driver: bridge
volumes:
db_data:
driver: local
rtt_db_data:
driver: local
portainer_data:
driver: local
app_data:
driver: local
app_backups:
driver: local
phapi_redis_cache:
driver: local