Last active
May 8, 2019 14:34
-
-
Save sinanm89/870d3b126f8b8e6ce8d4a8d21ff6fee6 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# TODO: the ports should be dynamically set from the data_service.env file | |
version: '3' | |
services: | |
my_app_service: | |
container_name: my_app | |
restart: "no" | |
build: | |
context: . | |
env_file: | |
- ./config/my_app.env | |
ports: | |
- 8003:8003 | |
network_mode: "host" | |
depends_on: | |
- "db" | |
db: | |
container_name: my_db | |
restart: "no" | |
build: | |
context: . | |
dockerfile: ./db/migrations/Dockerfile | |
ports: | |
- 5432:5432 | |
env_file: | |
- ./config/my_db.env | |
environment: | |
POSTGRES_PASSWORD: ${DB_PASSWORD:-test} | |
POSTGRES_USER: ${DB_USER:-postgres} | |
POSTGRES_DB: ${DB_NAME:-mydb} | |
volumes: | |
- db_data:/var/lib/postgresql/data | |
volumes: | |
db_data: |
Author
sinanm89
commented
May 1, 2019
•
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment