-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
74 lines (73 loc) · 2.13 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
# dockerpresso 2.1.0
services:
web:
image: wordpress:$WORDPRESS_VERSION
env_file: .env
restart: always
volumes:
- ./.wordpress_data:/var/www/html/
# uncomment line below to start theme development
# directory below should contain theme style.css file
# - ./example-theme-src:/var/www/html/wp-content/themes/example-theme
# uncomment line below to start plugin development
# directory below should contain main plugin PHP file
- .:/var/www/html/wp-content/plugins/gtm-ecommerce-woo
ports:
- "80:80"
links:
- mysql
mysql:
image: mysql
restart: always
env_file: .env
environment:
- MYSQL_DATABASE=${WORDPRESS_DB_NAME}
- MYSQL_USER=${WORDPRESS_DB_USER}
- MYSQL_PASSWORD=${WORDPRESS_DB_PASSWORD}
ports:
- "3306:3306"
volumes:
- mysql_data:/var/lib/mysql
web-cli:
profiles: ['cli']
image: wordpress:cli
command: bash
user: "33:33"
env_file: .env
volumes_from:
- web
links:
- web
- mysql
mysql-cli:
profiles: ['cli']
image: mysql
env_file: .env
links:
- mysql:mysql
command: bash -c 'exec mysql -hmysql -uroot -p$$MYSQL_ROOT_PASSWORD $$MYSQL_DATABASE'
environment:
- MYSQL_DATABASE=${WORDPRESS_DB_NAME}
- MYSQL_USER=${WORDPRESS_DB_USER}
- MYSQL_PASSWORD=${WORDPRESS_DB_PASSWORD}
volumes_from:
- mysql
php-cli:
profiles: ['cli']
image: composer
env_file: .env
command: bash
volumes:
- .:/app
mfrankiewicz-php-cli:
image: mfrankiewicz/php:7.1-cli
working_dir: /var/www
entrypoint: bash
environment:
SSH_AUTH_SOCK: ${SSH_AUTH_SOCK}
volumes:
- ${SSH_AUTH_SOCK}:${SSH_AUTH_SOCK}
- ~/.ssh/known_hosts:/root/.ssh/known_hosts
- ./:/var/www
volumes:
mysql_data: {}