-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose-local-dev.yml
155 lines (144 loc) · 4.39 KB
/
docker-compose-local-dev.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
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
version: "3.2"
services:
proxy:
image: nginx:latest
container_name: revisionary_proxy
restart: "always"
env_file:
- ./.env
ports:
- ${LOCAL_IP}:80:80
- ${LOCAL_IP}:443:443
volumes:
- ./proxy/templates:/etc/nginx/templates
- ./proxy/certificates:/etc/ssl/private
- ./proxy/logs:/var/log/nginx
- ./backend/src:/backend
networks:
- proxy-network
- backend-network
landing:
build: ./landing
image: revisionary_landing:latest
container_name: revisionary_landing
restart: "always"
volumes:
- ./landing/src:/landing/src
command: "npm run dev"
networks:
- proxy-network
environment:
HOST: 0.0.0.0
PORT: 3030
dashboard:
build: ./dashboard
image: revisionary_dashboard:latest
container_name: revisionary_dashboard
restart: "always"
depends_on:
- backend
volumes:
- ./dashboard/src:/dashboard/src
command: "npm run dev"
networks:
- backend-network
environment:
HOST: 0.0.0.0
PORT: 3000
API_ENDPOINT: https://${API_SUBDOMAIN}.${API_DOMAIN}/v1/
backend:
build: ./backend
image: revisionary_backend:latest
container_name: revisionary_backend
restart: "always"
depends_on:
- memcached
- database
env_file:
- ./.env
volumes:
#- ./backend/src/.htaccess:/backend/.htaccess # For Apache
- ./backend/src/app:/backend/app
- ./backend/src/assets:/backend/assets
- ./backend/src/cache:/backend/cache
- ./backend/src/index.php:/backend/index.php
- ./backend/logs:/var/log
networks:
- backend-network
memcached:
image: memcached:latest
container_name: revisionary_memcached
restart: "always"
command: ["-m", "512m"]
networks:
- backend-network
database:
image: mysql:latest
container_name: revisionary_database
restart: "unless-stopped"
command: [
"--character-set-server=utf8mb4",
"--collation-server=utf8mb4_unicode_ci",
"--slow_query_log=ON", # Make this off when in production !!!
"--long_query_time=2",
"--slow_query_log_file=/var/lib/mysql/mysql/slow_queries.log",
]
environment:
MYSQL_DATABASE: ${DB_NAME}
MYSQL_USER: ${DB_USER}
MYSQL_PASSWORD: ${DB_PASSWORD}
MYSQL_ROOT_PASSWORD: ${DB_ROOT_PASSWORD}
volumes:
- ./database/dump:/docker-entrypoint-initdb.d
- mysql:/var/lib/mysql
networks:
- backend-network
chrome:
build: ./chrome
user: www-data
image: revisionary_chrome:latest
container_name: revisionary_chrome
restart: "always"
ports:
- ${LOCAL_IP}:8080:3000
volumes:
- ./chrome/src:/chrome/src
- ./backend/src/cache:/chrome/cache
networks:
- backend-network
phpmyadmin:
image: phpmyadmin/phpmyadmin:latest
container_name: revisionary_phpmyadmin
restart: "unless-stopped"
depends_on:
- database
ports:
- ${LOCAL_IP}:8000:80
volumes:
- ./backend/config/phpmyadmin.ini:/usr/local/etc/php/conf.d/uploads.ini
environment:
PMA_HOSTS: ${DB_HOST}, ${DB_CLOUD_HOST}
PMA_PORTS: ${DB_PORT}, ${DB_CLOUD_PORT}
PMA_VERBOSES: Docker, Cloud
networks:
- backend-network
# memcachedadmin:
# build: ./memcachedadmin
# image: revisionary_memcachedadmin:latest
# container_name: revisionary_memcachedadmin
# restart: "unless-stopped"
# depends_on:
# - memcached
# ports:
# - ${LOCAL_IP}:1200:80
# volumes:
# - ./memcachedadmin/Memcache.docker.php:/var/www/localhost/htdocs/Config/Memcache.php
# networks:
# - backend-network
networks:
proxy-network:
driver: bridge
backend-network:
driver: bridge
volumes:
mysql: {}