initial commit
This commit is contained in:
38
docker-compose.yml
Normal file
38
docker-compose.yml
Normal file
@@ -0,0 +1,38 @@
|
||||
services:
|
||||
blog-manager:
|
||||
build:
|
||||
context: .
|
||||
dockerfile: Dockerfile
|
||||
# No authentication: binds on all interfaces and relies on host firewall
|
||||
# rules to restrict who can reach this port.
|
||||
ports:
|
||||
- "${BLOG_MANAGER_PORT:-3051}:3051"
|
||||
# Run as the host user that owns the portfolio checkout, so files written
|
||||
# into the bind mount (posts JSON, uploads, git objects) keep that owner.
|
||||
# Set BLOG_MANAGER_UID / BLOG_MANAGER_GID in .env (`id -u`, `id -g`).
|
||||
user: "${BLOG_MANAGER_UID:-1000}:${BLOG_MANAGER_GID:-1000}"
|
||||
environment:
|
||||
- NODE_ENV=production
|
||||
- NEXT_TELEMETRY_DISABLED=1
|
||||
- REPO_DIR=/repo
|
||||
# Commit identity (required unless the checkout's .git/config sets user.*).
|
||||
- GIT_AUTHOR_NAME=${GIT_AUTHOR_NAME:-}
|
||||
- GIT_AUTHOR_EMAIL=${GIT_AUTHOR_EMAIL:-}
|
||||
# Push: set GIT_PUSH=false to only commit. For an HTTPS remote, supply a
|
||||
# user + access token; they're handed to git via GIT_ASKPASS, never stored.
|
||||
- GIT_PUSH=${GIT_PUSH:-true}
|
||||
- GIT_PUSH_USER=${GIT_PUSH_USER:-}
|
||||
- GIT_PUSH_TOKEN=${GIT_PUSH_TOKEN:-}
|
||||
# Optional: the live site's redeploy hook (portfolio app/api/deploy).
|
||||
- DEPLOY_URL=${DEPLOY_URL:-}
|
||||
- DEPLOY_TRIGGER_SECRET=${DEPLOY_TRIGGER_SECRET:-}
|
||||
volumes:
|
||||
# The portfolio git checkout (read/write; .git is needed to publish).
|
||||
- ${PORTFOLIO_DIR:-../portfolio}:/repo
|
||||
restart: unless-stopped
|
||||
healthcheck:
|
||||
test: ["CMD", "wget", "--spider", "-q", "http://localhost:3051/api/health"]
|
||||
interval: 60s
|
||||
timeout: 5s
|
||||
retries: 3
|
||||
start_period: 10s
|
||||
Reference in New Issue
Block a user