mirror of
https://github.com/czhu12/canine.git
synced 2025-12-30 07:39:43 -06:00
47 lines
1.2 KiB
YAML
47 lines
1.2 KiB
YAML
services:
|
|
postgres:
|
|
image: postgres:16
|
|
environment:
|
|
- POSTGRES_USER=postgres
|
|
- POSTGRES_PASSWORD=password
|
|
- POSTGRES_MULTIPLE_DATABASES=canine_production,canine_development
|
|
ports:
|
|
- "5432:5432"
|
|
volumes:
|
|
- "postgres:/var/lib/postgresql/data"
|
|
|
|
redis:
|
|
image: redis:alpine
|
|
ports:
|
|
- "6379:6379"
|
|
|
|
web:
|
|
build:
|
|
context: .
|
|
dockerfile: Dockerfile
|
|
# Overrides default command so things don't shut down after the process ends.
|
|
# command: sleep infinity
|
|
depends_on:
|
|
- postgres
|
|
- redis
|
|
stdin_open: true
|
|
tty: true
|
|
ports:
|
|
- "${PORT:-3000}:${PORT:-3000}"
|
|
- "3200:3200"
|
|
environment:
|
|
- DATABASE_URL=postgres://postgres:password@postgres:5432
|
|
- REDIS_URL=redis://redis:6379
|
|
- PORT=${PORT:-3000}
|
|
- CANINE_USERNAME=${CANINE_USERNAME}
|
|
- CANINE_PASSWORD=${CANINE_PASSWORD}
|
|
- LOCAL_MODE=true
|
|
# This docker file is only expected to be used in the laptop deployment, so we can hardcode the secret key base
|
|
- SECRET_KEY_BASE=a38fcb39d60f9d146d2a0053a25024b9
|
|
- APP_HOST=http://localhost:${PORT:-3000}
|
|
volumes:
|
|
- ${DOCKER_SOCKET:-/var/run/docker.sock}:/var/run/docker.sock
|
|
|
|
volumes:
|
|
postgres:
|