-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
48 lines (46 loc) · 1.28 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
services:
db:
# We use a mariadb image which supports both amd64 & arm64 architecture
#image: mariadb:10.6.4-focal
# If you really want to use MySQL, uncomment the following line
image: mysql:8.0.27
command: '--default-authentication-plugin=mysql_native_password'
volumes:
- db_data:/var/lib/mysql
restart: always
environment:
MYSQL_ROOT_PASSWORD: secret
MYSQL_DATABASE: wordpress
MYSQL_USER: wordpress
MYSQL_PASSWORD: wordpress
wordpress:
build:
context: .
args:
WITH_XDEBUG: true
USER_NAME: "${USER}"
USER_ID: "1000" # ~$ id -u
GROUP_ID: "1000" # ~$ id -g
volumes:
- ./php-config.ini:/usr/local/etc/php/conf.d/php-config.ini
- ./wp-core:/var/www/html
# - ./my-theme:/var/www/html/wp-content/themes/my-theme
# - ./my-plugin:/var/www/html/wp-content/plugins/my-plugin
ports:
- 8080:80
restart: always
environment:
WORDPRESS_DB_HOST: db
WORDPRESS_DB_USER: wordpress
WORDPRESS_DB_PASSWORD: wordpress
WORDPRESS_DB_NAME: wordpress
WORDPRESS_DEBUG: 1
WORDPRESS_CONFIG_EXTRA: |
define('WP_DEBUG_LOG', true);
phpmyadmin:
image: phpmyadmin
restart: always
ports:
- 8081:80
volumes:
db_data: