Repository navigation
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
73 lines (67 loc) · 2.03 KB
/
Copy pathdocker-compose.yml
File metadata and controls
73 lines (67 loc) · 2.03 KB
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
version: "3"
services:
#######################################################
### POSTGRES
#######################################################
postgres:
container_name: ${APP_NAME}-postgres
image: postgres:10-alpine
volumes:
- '/var/lib/postgresql/data'
ports:
- 5432:5432
env_file:
- ${ENV_FILE_DIR}
restart: always
#######################################################
### PHP
#######################################################
php:
container_name: ${APP_NAME}-php
build: docker/php
user: www-data
volumes:
- ${SYMFONY_APP_PATH}:${SYMFONY_DOCKER_PATH}
env_file:
- ${ENV_FILE_DIR}
restart: always
#######################################################
### NGINX
#######################################################
nginx:
container_name: ${APP_NAME}-nginx
build: docker/nginx
ports:
- ${NGINX_PORT_EXPOSE}:${NGINX_PORT}
- ${NGINX_SSL_PORT_EXPOSE}:${NGINX_SSL_PORT}
links:
- php
volumes:
- ${SYMFONY_APP_PATH}:${SYMFONY_DOCKER_PATH}
env_file:
- ${ENV_FILE_DIR}
restart: always
#######################################################
### NODE
#######################################################
node:
container_name: ${APP_NAME}-node
build: docker/node
user: node
volumes:
- ${SYMFONY_APP_PATH}:${SYMFONY_DOCKER_PATH}
env_file:
- ${ENV_FILE_DIR}
command: sh -c "npm install && npm start"
restart: always
#######################################################
### REDIS
#######################################################
redis:
container_name: ${APP_NAME}-redis
image: redis:4-alpine
ports:
- ${REDIS_PORT_EXPOSE}:${REDIS_PORT}
env_file:
- ${ENV_FILE_DIR}
restart: always