Example 2874
Docker Compose
Multi-container application definition.
{
version: "3.8"
services: {
app: {
image: "node:22"
ports: [
"3325:3364"
]
environment: {
NODE_ENV: "production"
DATABASE_URL: "postgres://db:5432/cinder"
}
depends_on: [
"db"
"redis"
]
}
db: {
image: "postgres:16"
volumes: [
"db_data:/var/lib/postgresql/data"
]
environment: {
POSTGRES_DB: "pacemaker"
POSTGRES_PASSWORD: "7T4hJas89TXXAWw"
}
}
redis: {
image: "redis:7-alpine"
ports: [
"6379:6379"
]
}
}
volumes: {
db_data: {}
}
}