ConfigSentry

Guardrails for docker-compose.yml.

A tiny CLI linter that catches security + reliability footguns before they hit prod — locally or in CI.

Run locally (npx) Add GitHub Action GitHub
CI-friendly exit codes Actionable fixes SARIF → GitHub Code Scanning Baselines (incremental adoption)

Why

Compose files grow organically. A single line like privileged: true or mounting /var/run/docker.sock can silently turn a container into “root on host”. ConfigSentry surfaces the riskiest patterns early.

60-second quickstart

Local scan:

npx configsentry ./docker-compose.yml

Adopt incrementally (existing repo): generate a baseline once, commit it, then block only on new findings.

# generate baseline (non-blocking)
npx configsentry ./docker-compose.yml --write-baseline .configsentry-baseline.json

# CI: suppress baseline findings
npx configsentry ./docker-compose.yml --baseline .configsentry-baseline.json

Optional: fail only on HIGH severity (CI gating):

npx configsentry ./docker-compose.yml --severity-threshold high

Details: baselines docs

GitHub Action + Code Scanning (SARIF)

permissions:
  contents: read
  security-events: write

- uses: alfredMorgenstern/configsentry@v0.0.28
  with:
    target: .
    sarif: true
    upload-sarif: true
    # baseline: .configsentry-baseline.json
    # fail-on-findings: false

More: Action usage

Popular pages

Docker Compose linter Compose security best practices GitHub Code Scanning (SARIF)

What it checks

Proof in the wild

ConfigSentry is tested against public repositories (treated as untrusted, no repo code executed). Reports are published here:

Public repo tests →

Blog

Short, practical notes: baselines, CI gating, and Compose security footguns.

Read the blog →