forum/docker-compose.yml

50 lines
1.2 KiB
YAML
Raw Normal View History

2019-06-27 12:03:08 +02:00
version: "3.4"
2017-04-22 20:29:25 +02:00
services:
2019-06-27 12:03:08 +02:00
php:
build:
context: .
2019-12-03 21:00:08 +01:00
target: symfony_php
2017-10-26 14:51:56 +02:00
args:
SYMFONY_VERSION: ${SYMFONY_VERSION:-}
STABILITY: ${STABILITY:-stable}
2020-06-11 19:46:15 +02:00
SERVER_NAME: ${SERVER_NAME:-localhost}
2019-12-03 21:00:08 +01:00
healthcheck:
interval: 10s
timeout: 3s
retries: 3
start_period: 30s
2017-04-22 20:29:25 +02:00
volumes:
# Comment out the next line in production
- ./:/srv/app:rw,cached
2020-10-14 22:14:41 +02:00
- ./docker/php/conf.d/symfony.dev.ini:/usr/local/etc/php/conf.d/symfony.ini
# If you develop on Linux, comment out the following volumes to just use bind-mounted project directory from host
2020-10-14 22:14:41 +02:00
# - ./api/var:/srv/app/var:rw
environment:
- SYMFONY_VERSION
2017-04-22 20:29:25 +02:00
nginx:
build:
context: .
2019-12-03 21:00:08 +01:00
target: symfony_nginx
depends_on:
2019-06-27 12:03:08 +02:00
- php
2017-04-22 20:29:25 +02:00
volumes:
# Comment out the next line in production
2017-04-22 20:29:25 +02:00
- ./docker/nginx/conf.d:/etc/nginx/conf.d:ro
- ./public:/srv/app/public:ro
ports:
2019-06-27 12:03:08 +02:00
- "80:80"
2017-10-16 14:46:43 +02:00
# This HTTP/2 proxy is not secure: it should only be used in dev
h2-proxy:
build:
context: .
2019-12-03 21:00:08 +01:00
target: symfony_h2-proxy
2018-10-26 14:00:12 +02:00
depends_on:
- nginx
2017-10-16 14:46:43 +02:00
volumes:
2018-06-21 23:20:17 +02:00
- ./docker/h2-proxy/default.conf:/etc/nginx/conf.d/default.conf:ro
2017-10-16 14:46:43 +02:00
ports:
2019-06-27 12:03:08 +02:00
- "443:443"