-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
102 lines (92 loc) · 2.11 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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
version: '3.3'
services:
wordpress:
build:
context: ./docker
dockerfile: Dockerfile-wordpress
ports:
- 8080:80
environment:
WORDPRESS_DB_HOST: db
WORDPRESS_DB_USER: wp
WORDPRESS_DB_PASSWORD: wp
WORDPRESS_DB_NAME: wp
WORDPRESS_DEBUG: 1
WORDPRESS_CONFIG_EXTRA: |
define('SCRIPT_DEBUG', true );
define('BETTEREMBED_DEBUG', true );
volumes:
- wordpress:/var/www/html
- ./:/var/www/html/wp-content/plugins/betterembed
depends_on:
- db
command: bash /var/www/html/wp-content/plugins/betterembed/docker/docker-entrypoint.sh
db:
image: mysql:5.7
environment:
MYSQL_DATABASE: wp
MYSQL_USER: wp
MYSQL_PASSWORD: wp
MYSQL_RANDOM_ROOT_PASSWORD: '1'
volumes:
- db:/var/lib/mysql
testdb:
image: mysql:5.7
environment:
MYSQL_DATABASE: test
MYSQL_USER: test
MYSQL_PASSWORD: test
MYSQL_RANDOM_ROOT_PASSWORD: '1'
phpmyadmin:
image: phpmyadmin/phpmyadmin
ports:
- 127.0.0.1:8081:80
volumes:
- /sessions
environment:
- PMA_HOST=db
- PMA_USER=wp
- PMA_PASSWORD=wp
wp:
build:
context: ./docker
dockerfile: Dockerfile-wp
# https://github.com/docker-library/docs/tree/master/wordpress#running-as-an-arbitrary-user
user: "33:33"
working_dir: /var/www/html/wp-content/plugins/betterembed
volumes:
- wordpress:/var/www/html
- ./:/var/www/html/wp-content/plugins/betterembed
depends_on:
- wordpress
- db
scripts:
build:
context: ./docker
dockerfile: Dockerfile-scripts
user: 1000:1000
working_dir: /usr/var/app
volumes:
- .:/usr/var/app/
command: npm start
composer:
image: composer
user: 1000:1000
volumes:
- .:/app
tests:
build:
context: ./docker
dockerfile: Dockerfile-tests
user: 1000:1000
working_dir: /usr/var/app
volumes:
- .:/usr/var/app
- tests:/tmp
depends_on:
- testdb
command: [ "./vendor/bin/phpunit", "tests" ]
volumes:
wordpress:
db:
tests: