-
Notifications
You must be signed in to change notification settings - Fork 17
/
docker-compose.yml
56 lines (54 loc) · 1.27 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
55
56
version: "2"
services:
wp:
build:
context: ./
dockerfile: Dockerfile
ports:
- "8080:80"
volumes:
- ./wp-content/plugins:/var/www/html/wp-content/plugins:rw
- ./wp-content/themes:/var/www/html/wp-content/themes:rw
- ./data/wordpress:/var/www/html:rw
environment:
- WORDPRESS_DB_HOST=db
- WORDPRESS_DB_NAME=test
- WORDPRESS_DB_USER=root
- WORDPRESS_DB_PASSWORD=test
- WORDPRESS_LOCAL_DEV=true
restart: always
networks:
- test-network
db:
image: mariadb
restart: always
volumes:
- ./data/mysql/.db/mysql:/var/lib/mysql:rw
- ./data/mysql/:/data/mysql:rw
environment:
- MYSQL_DATABASE=test
- MYSQL_ROOT_PASSWORD=test
- MYSQL_USER=root
ports:
- "13303:3306"
networks:
- test-network
nginx:
image: nginx:alpine
restart: always
ports:
- "8081:80"
- "443:443"
depends_on:
- wp
volumes:
- ./data/nginx/wordpress.conf:/etc/nginx/conf.d/default.conf
- ./data/certs:/etc/nginx/certs/
- ./data/nginx/log:/var/log/nginx/
- ./data/wordpress:/var/www/html
- ./wp-content:/var/www/html/wp-content:rw
networks:
- test-network
networks:
test-network:
driver: bridge