Files
devops-directive-docker-course/04-building-container-images/sample-app/docker-compose.yml
2023-01-25 17:55:51 -05:00

47 lines
908 B
YAML

services:
client-react:
build:
context: ./client-react
dockerfile: Dockerfile
ports:
- 5173:5173
client-react-nginx:
build:
context: ./client-react
dockerfile: Dockerfile.3
init: true
ports:
- 5174:80
api-node:
build:
context: ./api-node
dockerfile: Dockerfile.7
init: true
depends_on:
- db
environment:
- PGUSER=postgres
- PGHOST=db
- PGPASSWORD=foobarbaz
- PGDATABASE=postgres
- PGPORT=5432
ports:
- 3000:3000
api-golang:
build:
context: ./api-golang
dockerfile: Dockerfile.6
init: true
depends_on:
- db
environment:
- DATABASE_URL=postgres://postgres:foobarbaz@db:5432/postgres
ports:
- 8080:8080
db:
image: postgres:15.1-alpine
environment:
- POSTGRES_PASSWORD=foobarbaz
ports:
- 5432:5432