forked from fishstix81/headless-wp-starter
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
54 lines (53 loc) · 1.64 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
version: '3'
services:
db-headless:
container_name: db-headless
environment:
- MYSQL_RANDOM_ROOT_PASSWORD=yes
- MYSQL_DATABASE=${WORDPRESS_DB_NAME}
- MYSQL_PASSWORD=${WORDPRESS_DB_PASSWORD}
- MYSQL_USER=${WORDPRESS_DB_USER}
image: mariadb
ports:
- '3307:3306'
wp-headless:
build: .
command: bash -c 'install_wordpress && apache2-foreground'
container_name: wp-headless
depends_on:
- db-headless
env_file: ./.env
ports:
- '8080:8080'
user: www-data
volumes:
- ./wordpress:/var/www/html
- ./docker/install_wordpress.sh:/usr/local/bin/install_wordpress
- ./docker/migratedb_import.sh:/usr/local/bin/migratedb_import
- ./docker/postlightheadlesswpstarter.wordpress.xml:/var/www/postlightheadlesswpstarter.wordpress.xml
- ./docker/images:/var/www/images
- ./docker/plugins:/var/www/plugins
frontend:
command: bash -c 'yarn && yarn start'
container_name: frontend
expose:
- '3000'
image: node
ports:
- '3000:3000'
user: node
volumes:
- ./frontend:/home/node/app
working_dir: /home/node/app
frontend-graphql:
command: bash -c 'yarn && yarn start'
container_name: frontend-graphql
expose:
- '3001'
image: node
ports:
- '3001:3001'
user: node
volumes:
- ./frontend-graphql:/home/node/app
working_dir: /home/node/app