Skip to content

feat: add Caddy web server provider#4534

Open
masonjames wants to merge 37 commits into
Dokploy:canaryfrom
masonjames:codex/caddy-web-server-v0296-clean-pr
Open

feat: add Caddy web server provider#4534
masonjames wants to merge 37 commits into
Dokploy:canaryfrom
masonjames:codex/caddy-web-server-v0296-clean-pr

Conversation

@masonjames
Copy link
Copy Markdown

Summary

Adds Caddy as a configurable web-server provider alongside Traefik.

  • adds provider-neutral web-server helpers and Caddy setup/config generation
  • adds Caddy route generation for dashboard, application, compose, and domain flows
  • adds guarded Traefik-to-Caddy migration dry-run/apply/rollback tooling
  • adds runtime upstream preflight, rollback snapshots, and migration operation locking
  • adds settings UI for provider selection and Caddy migration workflow
  • adds runtime Drizzle migration handling that fails closed if migrations cannot be applied

Safety model

  • Traefik remains the default provider
  • direct generic switching to or from Caddy is guarded; migration and rollback flows are required
  • Caddy config paths are constrained to Dokploy-owned config directories
  • manual Caddy fragments are detected and can block unsafe migration output conflicts
  • unsupported BasicAuth hashes are blocked instead of silently downgraded
  • rollback snapshots preserve Traefik resources and fail closed on missing artifacts
  • migration reports are sanitized for non-admin/public surfaces

Validation

  • git merge --no-commit --no-ff upstream/canary -> already up to date
  • git merge --no-commit --no-ff origin/codex/caddy-web-server-v0296-clean-pr -> already up to date
  • git diff --check upstream/canary..HEAD
  • pnpm exec biome check over 65 changed TS/TSX/JSON files
  • cd apps/dokploy && ./node_modules/.bin/tsc --noEmit --pretty false
  • pnpm --filter=dokploy test --run __test__/db __test__/caddy __test__/traefik/server/update-server-config.test.ts -> 14 files / 84 tests passed
  • docker run --rm caddy:2.11.3 caddy validate --help

@masonjames masonjames requested a review from Siumauricio as a code owner June 1, 2026 23:07
@dosubot dosubot Bot added size:XL This PR changes 500-999 lines, ignoring generated files. enhancement New feature or request labels Jun 1, 2026
@masonjames masonjames marked this pull request as draft June 1, 2026 23:08
@masonjames masonjames marked this pull request as ready for review June 1, 2026 23:10
@dosubot
Copy link
Copy Markdown

dosubot Bot commented Jun 1, 2026

Related Knowledge

1 document with suggested updates is ready for review.

Dokploy's Space

README /dokploy/blob/canary/README.md — ⏳ Awaiting Merge

How did I do? Any feedback?  Join Discord

@masonjames masonjames force-pushed the codex/caddy-web-server-v0296-clean-pr branch from 46a438e to 7baf056 Compare June 2, 2026 10:40
@dosubot dosubot Bot added size:XS This PR changes 0-9 lines, ignoring generated files. and removed size:XL This PR changes 500-999 lines, ignoring generated files. labels Jun 2, 2026
@masonjames masonjames mentioned this pull request Jun 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request size:XS This PR changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant