You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
46 lines
817 B
46 lines
817 B
version: '3.8'
|
|
|
|
services:
|
|
app:
|
|
build:
|
|
context: .
|
|
dockerfile: Dockerfile
|
|
target: production
|
|
container_name: koa3-demo-app
|
|
restart: unless-stopped
|
|
ports:
|
|
- "3000:3000"
|
|
environment:
|
|
- NODE_ENV=production
|
|
- BUN_ENV=production
|
|
- PORT=3000
|
|
volumes:
|
|
- ./database:/app/database
|
|
- ./logs:/app/logs
|
|
networks:
|
|
- app-network
|
|
healthcheck:
|
|
test: ["CMD", "bun", "--version"]
|
|
interval: 30s
|
|
timeout: 10s
|
|
retries: 3
|
|
start_period: 40s
|
|
depends_on:
|
|
- db
|
|
|
|
db:
|
|
image: sqlite:latest
|
|
container_name: koa3-demo-db
|
|
restart: unless-stopped
|
|
volumes:
|
|
- ./database:/var/lib/sqlite
|
|
networks:
|
|
- app-network
|
|
|
|
networks:
|
|
app-network:
|
|
driver: bridge
|
|
|
|
volumes:
|
|
database:
|
|
logs:
|
|
|