-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
54 lines (51 loc) · 1.49 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
services:
wordpress:
container_name: wordpress
image: wordpress
restart: always
ports:
- 8086:80
environment:
WORDPRESS_DB_HOST: db
WORDPRESS_DB_USER: exampleuser
WORDPRESS_DB_PASSWORD: examplepass
WORDPRESS_DB_NAME: exampledb
depends_on:
- db
volumes:
- ./wp/plugins:/var/www/html/wp-content/plugins
- ./wp/mu-plugins:/var/www/html/wp-content/mu-plugins
- ./wp/themes:/var/www/html/wp-content/themes
- ./wp/upgrade:/var/www/html/wp-content/upgrade
- ./wp/db-backups:/var/www/html/db-backups
- wordpress:/var/www/html
wpcli:
container_name: wpcli
depends_on:
- wordpress
image: wordpress:cli
user: 1000:1000
command: tail -f /dev/null
volumes:
- wordpress:/var/www/html
environment:
WORDPRESS_DB_HOST: db
WORDPRESS_DB_USER: exampleuser
WORDPRESS_DB_PASSWORD: examplepass
WORDPRESS_DB_NAME: exampledb
db:
container_name: db
image: mariadb:latest
restart: always
ports:
- 3307:3306
environment:
MYSQL_DATABASE: exampledb
MYSQL_USER: exampleuser
MYSQL_PASSWORD: examplepass
MYSQL_RANDOM_ROOT_PASSWORD: '1'
volumes:
- db:/var/lib/mysql
volumes:
db:
wordpress: