-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
53 lines (53 loc) · 1.43 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
version: '3'
services:
webserver:
image: nginx
depends_on:
- app
ports:
- '${WEBSERVER_HTTP_PORT}:80'
restart: 'unless-stopped'
volumes:
- ./webserver/nginx.conf.d:/etc/nginx/conf.d
- ./webserver/ssl:/etc/ssl
- './app:/app'
app:
build:
context: .
dockerfile: Dockerfile-php8_2
depends_on:
- db
restart: 'unless-stopped'
volumes:
- './app:/app'
- './webserver/php/app.ini:/usr/local/etc/php/conf.d/app.ini'
- './supervisor/supervisord.conf:/etc/supervisor/supervisord.conf'
- './supervisor/conf.d:/etc/supervisor/conf.d'
environment:
- "DB_PASSWORD=${MYSQL_PASSWORD}"
- "APP_URL=http://localhost:${DB_PORT}"
- "DBEXCLUDE=performance_schema information_schema"
- "CRON_SCHEDULE=0 * * * *"
- "EXTRA_OPTS=--single-transaction"
db:
image: mysql:8
restart: 'unless-stopped'
ports:
- '${DB_PORT}:3306'
volumes:
- './db:/var/lib/mysql'
env_file: './.env'
command: --sql_mode=""
mysqlbackup:
image: selim13/automysqlbackup:2.6-7-debian
volumes:
- './db_backups:/backup'
environment:
USERNAME: root
PASSWORD: "${MYSQL_ROOT_PASSWORD}"
DBHOST: db
DBEXCLUDE: "performance_schema information_schema"
CRON_SCHEDULE: "0 * * * *"
EXTRA_OPTS: "--single-transaction"
depends_on:
- db