forked from tarlepp/symfony-flex-backend
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
55 lines (52 loc) · 1.48 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
version: '3'
services:
php:
build:
context: .
dockerfile: ./Dockerfile_dev
args:
HOST_UID: $HOST_UID
HOST_GID: $HOST_GID
command: php-fpm
user: $HOST_UID:$HOST_GID
depends_on:
- mysql
ports:
- 9000:9000
volumes:
- ./:/app:cached
# Cannot use this because of the directory rights are forced for root user
#- /app/var/
environment:
PHP_IDE_CONFIG: "serverName=app.localhost"
# Eg. in GCP environment just set this environment variable
# to your k8s configuration.
#
# https://symfony.com/doc/current/deployment/proxies.html
TRUSTED_PROXIES: "127.0.0.1,REMOTE_ADDR"
nginx:
build:
context: ./docker/nginx/
args:
HOST_UID: $HOST_UID
HOST_GID: $HOST_GID
depends_on:
- php
ports:
- 8000:80
volumes:
- ./:/app:cached
# Cannot use this because of the directory rights are forced for root user
#- /app/var/
mysql:
build:
context: ./docker/mysql/
command: --default-authentication-plugin=mysql_native_password
environment:
MYSQL_ROOT_PASSWORD: password
ports:
- 3310:3306
volumes:
- mysql:/var/lib/mysql
volumes:
mysql: