-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
34 lines (32 loc) · 993 Bytes
/
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
version: "3.9"
services:
mysql:
image: mysql:5.7
volumes:
- ./mysql:/var/lib/mysql
ports:
- "${MYSQL_PORT_NUMBER}"
restart: always
environment:
MYSQL_USER: "${MYSQL_USER}"
MYSQL_DATABASE: "${MYSQL_DATABASE}"
MYSQL_PASSWORD: "${MYSQL_PASSWORD}"
MYSQL_ALLOW_EMPTY_PASSWORD: "${MYSQL_ALLOW_EMPTY_PASSWORD}"
MYSQL_ROOT_PASSWORD: "${MYSQL_ROOT_PASSWORD}"
wordpress:
depends_on:
- mysql
image: wordpress:5.7.2
volumes:
- ./wordpress:/var/www/html
ports:
- "${WORDPRESS_PORT_NUMBER}:80"
restart: always
environment:
WORDPRESS_DB_HOST: "mysql:${MYSQL_PORT_NUMBER}"
WORDPRESS_DB_USER: "${WORDPRESS_DB_USER}"
WORDPRESS_DB_NAME: "${WORDPRESS_DB_NAME}"
WORDPRESS_DB_PASSWORD: "${WORDPRESS_DB_PASSWORD}"
WORDPRESS_TABLE_PREFIX: "${WORDPRESS_TABLE_PREFIX}"
WORDPRESS_DEBUG: "${WORDPRESS_DEBUG}"
WORDPRESS_CONFIG_EXTRA: "${WORDPRESS_CONFIG_EXTRA}"