-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
62 lines (56 loc) · 1.26 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
version: '3'
services:
nginx:
image: nginx:stable-alpine
ports:
- "8080:80"
volumes:
- ./php:/var/www/html
- ./nginx/default.conf:/etc/nginx/conf.d/default.conf
depends_on:
- php
- db
db:
image: percona:5.7.26-centos
restart: unless-stopped
volumes:
- ./mysql/dump:/docker-entrypoint-initdb.d
- ./mysql/conf.d:/etc/mysql/conf.d
- dbPersistent:/var/lib/mysql
environment:
MYSQL_DATABASE: ${MYSQL_DATABASE}
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
MYSQL_USER: ${MYSQL_USER}
MYSQL_PASSWORD: ${MYSQL_PASSWORD}
php:
build:
context: ./php
dockerfile: Dockerfile
args:
- USER_ID=${USER_ID}
- GROUP_ID=${GROUP_ID}
volumes:
- ./php:/var/www/html
depends_on:
- db
phpmyadmin:
image: phpmyadmin/phpmyadmin
links:
- db:db
ports:
- ${PMA_PORT}:80
depends_on:
- db
environment:
MYSQL_USER: ${MYSQL_USER}
MYSQL_PASSWORD: ${MYSQL_PASSWORD}
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
npm:
image: node:13.7
user: ${USER_ID}:${GROUP_ID}
volumes:
- ./php:/var/www/html
working_dir: /var/www/html/src
entrypoint: ['npm']
volumes:
dbPersistent: