Gitless Mode (OCI Artifacts)¶
DockerWorks can run 100% gitless by pulling Compose files, Podman Quadlets, and encrypted SOPS configs directly from any OCI-compatible container registry (GitHub Packages GHCR, zot, registry:2, AWS ECR, etc.).
How It Works¶
- Your CI/CD pipeline packages deployment files (
docker-compose.yml,*.container,prometheus.yml,secrets.enc.env) and pushes them as an OCI artifact usingorasor as a minimal OCI config image. - DockerWorks polls the artifact's manifest digest using lightweight
HEAD/GETrequests. - When the digest changes, DockerWorks pulls and safely extracts the files into
work_dir(supporting both ORAS raw-file layers and tar/tar+gzip layers, with path-traversal protection). - DockerWorks runs
deploy(andsops --decryptif configured) and monitors container/unit health. - On healthcheck failure, DockerWorks pulls the previous immutable
@sha256:...digest from the registry and rolls back.
Example: CI Push + DockerWorks Config¶
1. Push config bundle from CI (oras)¶
oras push ghcr.io/myorg/my-app-config:latest \
docker-compose.yml \
configs/prometheus.yml \
secrets.enc.env
2. Configure apps[].oci in config.yaml¶
apps:
- name: "my-app"
env_files:
- "secrets.env"
oci:
artifact: "ghcr.io/myorg/my-app-config:latest"
poll_interval: "2m"
auth:
ghcr.io:
token: "${GHCR_TOKEN}"
sops:
age_key: "${SOPS_AGE_KEY}"
files:
- source: "secrets.enc.env"
target: "secrets.env"
auto_rollback: true
auto_prune: true
(If oci.auth is omitted, DockerWorks falls back to ~/.docker/config.json and Podman's auth.json.)
Combining with Watch Images or Webhooks¶
- You can pair
oci:(for Compose/Quadlet config updates) withregistry:(for app container image updates) in the same app, or useoci:alone. - Trigger an immediate OCI pull + deploy anytime via
POST /webhooks/{app}ordocker-works sync --app my-app.