Files
my-protfolio/compose.yaml
Amirhossein Khalili dcce6d219d
All checks were successful
Test and deploy / Verify production build (push) Successful in 10m25s
ci: deploy the verified local image
Build and test the Next.js application once with persistent BuildKit caches, smoke-test the immutable runtime image, and activate that same image through the shared production Docker daemon with serialized rollback-safe deployment.
2026-09-15 15:00:19 +03:30

30 lines
618 B
YAML

services:
portfolio-app:
image: ${PORTFOLIO_IMAGE:-amiirkhl-portfolio:latest}
container_name: portfolio-app
restart: unless-stopped
healthcheck:
test:
[
"CMD",
"node",
"-e",
"fetch('http://127.0.0.1:3000/').then(r=>{if(!r.ok)process.exit(1)}).catch(()=>process.exit(1))",
]
interval: 2s
timeout: 2s
start_period: 3s
retries: 30
volumes:
- next-image-cache:/app/.next/cache
networks:
- caddy_proxy
networks:
caddy_proxy:
external: true
name: caddy_proxy
volumes:
next-image-cache: