Local .env logic for webpack custom port

This commit is contained in:
Eliot Berriot 2018-03-29 19:55:24 +02:00
commit 96d219dfe2
No known key found for this signature in database
GPG key ID: DD6965E2476E5C27
4 changed files with 36 additions and 10 deletions

30
dev.yml
View file

@ -1,27 +1,35 @@
version: '2'
version: '3'
services:
front:
build: front
env_file: .env.dev
env_file:
- .env.dev
- .env
environment:
- "HOST=0.0.0.0"
- "WEBPACK_DEVSERVER_PORT=${WEBPACK_DEVSERVER_PORT-8080}"
ports:
- "8080:8080"
- "${WEBPACK_DEVSERVER_PORT-8080}:${WEBPACK_DEVSERVER_PORT-8080}"
volumes:
- './front:/app'
postgres:
env_file: .env.dev
env_file:
- .env.dev
- .env
image: postgres
redis:
env_file: .env.dev
env_file:
- .env.dev
- .env
image: redis:3.0
celeryworker:
env_file: .env.dev
env_file:
- .env.dev
- .env
build:
context: ./api
dockerfile: docker/Dockerfile.test
@ -41,7 +49,9 @@ services:
- ./api:/app
- ./data/music:/music
api:
env_file: .env.dev
env_file:
- .env.dev
- .env
build:
context: ./api
dockerfile: docker/Dockerfile.test
@ -62,7 +72,9 @@ services:
- redis
nginx:
env_file: .env.dev
env_file:
- .env.dev
- .env
image: nginx
links:
- api