Files
rfid-database/docker-compose.yml
T
Cursor Agent 8ba92654c0 Publish Docker image to GHCR on main builds
Add a Docker workflow that builds on PRs and pushes to
ghcr.io/chewbaccalakis/rfid-database on main (latest + sha) and v* tags.
Drop the redundant docker-build job from CI.
2026-08-24 04:06:00 +00:00

40 lines
1.1 KiB
YAML

services:
rfid-database:
# Local build (default):
build:
context: .
dockerfile: Dockerfile
image: rfid-database:local
# Or pull from GHCR instead of building:
# image: ghcr.io/chewbaccalakis/rfid-database:latest
# pull_policy: always
container_name: rfid-database
restart: unless-stopped
ports:
- "${RFID_PORT:-3000}:3000"
env_file:
- .env
environment:
NODE_ENV: production
RFID_DB_PATH: /data/rfid.db
PORT: "3000"
HOSTNAME: 0.0.0.0
AUTH_TRUST_HOST: "true"
# OIDC: set AUTH_OIDC_ISSUER / CLIENT_ID / CLIENT_SECRET (and AUTH_URL)
# in .env — the login page picks them up at runtime.
# Optional bootstrap (only creates if missing):
# CREATE_USER_EMAIL: [email protected]
# CREATE_USER_PASSWORD: change-me
# CREATE_USER_NAME: Admin
volumes:
- rfid-data:/data
healthcheck:
test: ["CMD", "curl", "-fsS", "http://127.0.0.1:3000/login"]
interval: 30s
timeout: 5s
retries: 3
start_period: 25s
volumes:
rfid-data: