Commit Graph

1720 Commits

Author SHA1 Message Date
autofix-ci[bot]
ebeb95cefd
[autofix.ci] apply automated fixes 2026-08-27 06:42:22 +00:00
Mauricio Siu
2d8dfee9f3 fix(server): keep ${VAR} self-references interpolatable in .env files
Only escape $ signs that are not part of a well-formed ${VAR} reference
when writing .env files, so Docker Compose's own variable interpolation
still works for legitimate ASSET_URL=${APP_URL}-style references, while
literal dollar signs (e.g. in passwords) stay escaped.

Fixes #5151
2026-08-27 00:41:17 -06:00
Mauricio Siu
3c6a96a30a
Merge pull request #5141 from Dokploy/fix/monitoring-zombie-container
Some checks are pending
Auto PR to main when version changes / create-pr (push) Waiting to run
Build Docker images / build-and-push-cloud-image (push) Waiting to run
Build Docker images / build-and-push-schedule-image (push) Waiting to run
Build Docker images / build-and-push-server-image (push) Waiting to run
Dokploy Docker Build / docker-amd (push) Waiting to run
Dokploy Docker Build / docker-arm (push) Waiting to run
Dokploy Docker Build / combine-manifests (push) Blocked by required conditions
Dokploy Docker Build / generate-release (push) Blocked by required conditions
Dokploy Docker Build / sync-version (push) Blocked by required conditions
autofix.ci / format (push) Waiting to run
Dokploy Monitoring Build / docker-amd (push) Waiting to run
Dokploy Monitoring Build / docker-arm (push) Waiting to run
Dokploy Monitoring Build / combine-manifests (push) Blocked by required conditions
fix(monitoring): remove legacy container and default empty cronJob
2026-08-27 00:03:36 -06:00
somuai
bd8ba128cd fix(server): allow plus, at, and valid path characters in readValidDirectory 2026-08-26 04:54:13 +05:30
Narciso
e2ab2eb6bc remove unused code 2026-08-24 20:52:35 -04:00
Aditya Nandlal
ede4626396 fix(traefik): skip empty service reconnect 2026-08-22 08:02:21 +00:00
Narciso
bee6918d9a fix(monitoring): remove legacy container and default empty cronJob
The swarm migration in 3848fa9c0 dropped the container.remove({force:true})
that the standalone deploy path used to run. Swarm tasks are named
dokploy-monitoring.<slot>.<id>, so there is no name collision and the
pre-v0.30.0 container survives every redeploy. It also stays pinned to an
orphaned image ID once pullRemoteImage moves the latest tag, so neither a
pull nor a Save clears it and it restarts forever.

Cloud setup spread metricsConfig straight from the row, shipping
cronJob: "" to the agent. robfig/cron rejects an empty spec, so the Go
binary exits before Fiber binds 4500 and Docker restarts it every ~60s.

- remove the legacy container in deployMonitoringService, which covers both
  setupMonitoring and setupWebMonitoring. Cleanup is best effort: a failure
  is logged and the deploy continues, matching the pre-migration behaviour
- default cronJob when configuring monitoring for cloud
- on build servers, clean up the legacy container but deploy no service.
  They never join the swarm, yet cloud setup did create the standalone
  container there before v0.30.0, and the monitoring form has always been
  hidden for them, so those agents are all stuck with an empty cronJob
- cover the above with real-docker tests
2026-08-20 11:17:41 -04:00
Narciso E. Núñez Arias
3054cf53be
Merge pull request #5082 from bestmaa/fix/volume-backup-restart
fix(volume-backups): restart services after backup failure
2026-08-18 18:40:08 -04:00
Mauricio Siu
d183018201 fix: don't quote .env values for stack deploys
docker stack deploy reads env_file literally without stripping
quotes (unlike docker compose), so the quoting/escaping added to
fix #4694 was shipping literal quote characters into stack
containers.

Fixes #5096, #5110.
2026-08-18 15:20:55 -06:00
Narciso E. Núñez Arias
ded23bb05f
Merge pull request #4660 from pparage/fix/ubuntu-26.04-docker-version
Some checks are pending
Auto PR to main when version changes / create-pr (push) Waiting to run
Build Docker images / build-and-push-cloud-image (push) Waiting to run
Build Docker images / build-and-push-schedule-image (push) Waiting to run
Build Docker images / build-and-push-server-image (push) Waiting to run
Dokploy Docker Build / docker-amd (push) Waiting to run
Dokploy Docker Build / docker-arm (push) Waiting to run
Dokploy Docker Build / combine-manifests (push) Blocked by required conditions
Dokploy Docker Build / generate-release (push) Blocked by required conditions
Dokploy Docker Build / sync-version (push) Blocked by required conditions
autofix.ci / format (push) Waiting to run
Dokploy Monitoring Build / docker-amd (push) Waiting to run
Dokploy Monitoring Build / docker-arm (push) Waiting to run
Dokploy Monitoring Build / combine-manifests (push) Blocked by required conditions
fix(setup): install Docker 29.4.2 on Ubuntu 26.04 to fix failed setup
2026-08-17 12:45:37 -04:00
Shuvo
2cb499fb64 fix: prevent Postgres 100-argument limit crash and restore data parity for restricted-member project access
The application table has 101 columns. The restricted-member branch of
project.one (apps/dokploy/server/api/routers/project.ts) queried the
applications relation with no columns narrowing, so Drizzle's relational
query builder generated a json_build_array call with one argument per
column, exceeding Postgres's FUNC_MAX_ARGS (100). Any non-owner/admin
member with limited access to a project containing at least one
application hit an opaque INTERNAL_SERVER_ERROR and got redirected away
from the project/environment page instead of seeing their project.

The same branch was also missing the "server" relation that the
owner/admin path (findProjectById) already includes, so restricted
members saw different (incomplete) data than owners/admins for the same
project.

Fixes this by extracting the existing serviceColumns column-selection
constant to a module-level export in packages/server/src/services/project.ts
and applying it (plus the server relation) to all 8 service relations in
the restricted-member query path, matching the owner/admin path.
2026-08-17 13:37:11 +06:00
Aditya Nandlal
c6ab76fe09 fix(volume-backups): preserve backup failure status 2026-08-14 12:51:28 +00:00
Aditya Nandlal
2598a62771 fix(volume-backups): restart services after backup failure 2026-08-14 11:40:21 +00:00
Mauricio Siu
8bc1bd36d8 style: format overview.ts (biome)
Some checks failed
Auto PR to main when version changes / create-pr (push) Waiting to run
Build Docker images / build-and-push-cloud-image (push) Waiting to run
Build Docker images / build-and-push-schedule-image (push) Waiting to run
Build Docker images / build-and-push-server-image (push) Waiting to run
Dokploy Docker Build / docker-amd (push) Waiting to run
Dokploy Docker Build / docker-arm (push) Waiting to run
Dokploy Docker Build / combine-manifests (push) Blocked by required conditions
Dokploy Docker Build / generate-release (push) Blocked by required conditions
Dokploy Docker Build / sync-version (push) Blocked by required conditions
autofix.ci / format (push) Waiting to run
Dokploy Monitoring Build / docker-amd (push) Waiting to run
Dokploy Monitoring Build / docker-arm (push) Waiting to run
Dokploy Monitoring Build / combine-manifests (push) Blocked by required conditions
Generate and Sync OpenAPI / Generate OpenAPI and commit to Dokploy repo (push) Has been cancelled
2026-08-14 00:51:15 -06:00
Mauricio Siu
1828e7c276
Merge pull request #5076 from Dokploy/feat/overview-dashboard
feat: add Overview dashboard (Services, Backups & Domains tabs)
2026-08-14 00:40:13 -06:00
Mauricio Siu
d770e3ce7d feat: implement utility functions to streamline owner selection for backups and domains 2026-08-14 00:40:00 -06:00
Narciso
046a608f8c feat: add Overview dashboard (Services, Backups & Domains tabs) 2026-08-13 17:03:42 -04:00
Mauricio Siu
171c70492d refactor: remove deployment failure classifier and related tests 2026-08-13 15:03:35 -06:00
Mauricio Siu
a4425cfb1d Merge branch 'canary' into feat/docker-health-dashboard 2026-08-13 14:45:23 -06:00
Mauricio Siu
fc5b8d03e5 fix(gitlab): handle missing expires_in in OAuth token response
Some self-hosted GitLab instances (e.g. older versions without
expires_in configured in doorkeeper) omit expires_in from the
OAuth token response. Computing Date.now()/1000 + undefined
produced NaN, which Postgres rejected on the expires_at integer
column, crashing both the initial OAuth callback and the token
refresh flow with a 500.

Falls back to null when expires_in is absent, matching the
existing Gitea callback behavior.

Closes #4362
2026-08-13 14:41:10 -06:00
Narciso
95b1afc2c2 fix: correct log-tail server resolution, drop unrelated Networks gating
- Log tail for failed-deployment classification now checks the app's
  current buildServer before falling back to its server, matching the
  buildServerId-then-serverId precedence used everywhere else in the
  codebase (application.ts, drop.ts, directory.ts, patch-repo.ts).
- Removes a stale !isCloud gate on the Networks tab that this branch
  had reintroduced from before Mauricio removed it in daba2d7fb
  (Networks is intentionally shown in cloud now) — unrelated to this
  PR's scope, docker.tsx's Networks tab/content now matches canary.
2026-08-13 12:03:38 -04:00
Narciso
795065810d chore: trim multi-line comments to single lines
Tightens a handful of two-line comments left over from earlier
iterations (Health tab / failed-deployment classification) down to
one line each, no behavior change.
2026-08-13 10:27:02 -04:00
Narciso
4bf6dfff13 feat: add Docker Health diagnostics tab
Server diagnostics tab (Docker dashboard) with:
- Per-network IP usage: subnet capacity vs. containers in use, including
  reserved networks like dokploy-network which are excluded from the
  managed Networks tab. Surfaces read errors instead of silently showing
  zeroes when the Docker API call fails.
- Broadened daemon-error detection and failure classification for Swarm
  network failures: IP pool exhaustion on an existing network
  ("could not find an available IP", "task allocation failure") and
  network attach timeouts ("attaching to network failed", "context
  deadline exceeded") — both previously fell through as Unclassified.
  Verified end-to-end against a real systemd-managed dockerd.
- Failed-deployment rows now carry the raw log tail used for
  classification, shown on hover and linked to their service/project,
  so a guess (or lack of one) can be verified against the actual error
  and followed straight to the app.
- Daemon-error panel is a read-only code editor, always visible (not
  hidden when empty), prefixed with the actual "Logs from X to Y"
  window passed to journalctl so the --since window can be verified.
- "Download report" exports everything on screen (metrics + raw logs)
  as Markdown, so a customer can send one file instead of a screen-share.
- Health check now IS_CLOUD-gated the same way network sync already is:
  a cloud org can no longer omit serverId and have the check silently
  run against the shared platform host instead of their own server.

Includes an inotify diagnostics card (current vs. max_user_instances/
watches/queued_events) and a failed-deployments log with automatic
cause classification based on daemon/log error patterns.
2026-08-13 10:00:54 -04:00
Mauricio Siu
a1a672b672 fix(auth): link SCIM-provisioned users through SSO and surface sign-in errors
SCIM provisioning created users with emailVerified: false, so better-auth
refused to link the matching SSO account (account_not_linked), and the
resulting redirect landed on better-auth's bare /error page with no
actionable feedback.

- Mark SCIM-provisioned users as email-verified at creation time, same
  trust rationale already applied to admin-invited credential users.
- Sync a SCIM user's membership role to the organization's configured
  default role instead of the hardcoded "member" the SCIM plugin creates.
- Set errorCallbackURL/onAPIError.errorURL to the sign-in page so failed
  SSO/OAuth callbacks land back on Dokploy's UI instead of better-auth's
  generic error page.
- Read the error query param on the sign-in page and show it through the
  existing AlertBlock instead of failing silently.

Fixes #4973
2026-08-13 02:11:15 -06:00
Mauricio Siu
f6c1e77279 feat: implement session management with filtering and sorting capabilities 2026-08-13 01:22:49 -06:00
Narciso E. Núñez Arias
2bda2ccc04
Merge pull request #4543 from linkthai/fix/mongo-replicaSets-false-after-update
FIX: replicaSets default to false after updating mongo due to default
2026-08-12 12:49:42 -04:00
Narciso E. Núñez Arias
4e18a64da2
Merge pull request #4710 from elijahdev0/fix/add-source-type-to-create-apis
fix: add sourceType to apiCreateCompose and apiCreateApplication
2026-08-12 12:08:18 -04:00
Narciso E. Núñez Arias
3e10a8dd6d
Merge pull request #4795 from yusoofsh/fix/4794-preserve-compose-mounts
fix(compose): preserve raw remote mounts
2026-08-12 11:47:04 -04:00
Mauricio Siu
c2071bbbfd feat: add Images and Disk Usage tabs to docker dashboard
- Images tab: list, inspect and delete docker images, with a
  force-delete fallback when an image is in use.
- Disk Usage tab: docker system df summary as stat cards plus a
  Build Cache table (docker system df -v) with a prune action.
2026-08-12 04:30:19 -06:00
Mauricio Siu
9412b52172 fix: disable minimumReleaseAge (broke builds on unrelated AWS SDK deps)
@aws-sdk/client-secrets-manager (pre-existing, unrelated to any recent
PR) transitively pulled @smithy/fetch-http-handler + @smithy/core
versions published the same day, with no older compatible version to
fall back to. AWS SDK v3 is dozens of interdependent packages often
published together same-day, so a global minimumReleaseAge with no
per-scope threshold (pnpm only supports all-or-nothing exclude) was
going to keep breaking builds on any lockfile touch. Commented out
rather than deleted -- left for whoever wants to revisit it, see
discussion on #4679.

Also lets @aws-sdk/client-route-53 and @aws-sdk/client-secrets-manager
resolve to their actual latest versions now that nothing blocks it.
2026-08-12 04:26:27 -06:00
Mauricio Siu
7825537964
Merge pull request #5059 from Dokploy/feat/docker-events-tab
feat: add Docker events tab to docker dashboard
2026-08-12 04:11:48 -06:00
Mauricio Siu
daba2d7fbc feat: add Docker events tab to docker dashboard
Adds a new Events tab to /dashboard/docker showing Docker daemon
events (equivalent to `docker events`), polled via docker.getEvents
with a time-range selector and refresh button.

Also fixes a stale isCloud redirect that forced the Networks tab
back to Containers even though it is now shown in cloud.
2026-08-12 04:07:59 -06:00
Mauricio Siu
02edd6abe7 fix: remove Route53 endpoint override and pin AWS SDK to an aged version
The endpoint field let anyone with dnsProvider create permission point
the AWS SDK at an arbitrary URL (loopback, link-local, internal
network, cloud metadata), turning testConnection and every other
Route53 operation into an SSRF oracle. There's no way to keep
LocalStack-style testing working while blocking that, since the
target address is identical either way, so the field is removed
entirely rather than validated. Route53 always talks to real AWS now.

Also pin @aws-sdk/client-route-53 to ^3.1097.0 (matching the existing
client-secrets-manager pin) instead of whatever caret-latest resolved
to at install time. The version that landed in the merged PR was
published less than a day before this, which violates the
minimumReleaseAge policy that merged into canary around the same time
and broke the Docker build.
2026-08-12 04:01:01 -06:00
Mauricio Siu
4d58f3987f feat: add DNS provider integration (Cloudflare, AWS Route53)
Lets you connect a DNS provider and manage its records (create,
update, delete) from Settings -> DNS Providers, instead of doing it
by hand in Cloudflare/AWS.

- dns_provider table, org-scoped, jsonb config as a discriminated
  union per provider type
- Cloudflare adapter (REST, bearer token)
- Route53 adapter (AWS SDK, SigV4); records are identified by
  type:name since Route53 has no native record id, so update
  handles renames as delete-old + upsert-new
- listZones/listRecords/createRecord/updateRecord/deleteRecord/
  testConnection wired through a shared DnsClient interface
- Settings UI: provider management, zone browser, record CRUD,
  IP-fill dropdown for A records (panel IP + remote servers)
- Access control: dnsProvider resource wired into custom roles
- Unit tests for both adapters and the config mask/merge logic
2026-08-12 03:25:25 -06:00
Mauricio Siu
3848fa9c0d
fix: deploy monitoring as a swarm service instead of a standalone container (#5055)
Monitoring was the only component still using docker.createContainer
directly instead of docker.createService like every other Dokploy
component (postgres, traefik, forward-auth, etc). This meant it never
benefited from Swarm's own reconciliation, relying only on Docker's
restart policy with no self-healing if the daemon didn't come back
cleanly after a reboot.

Also removed the try/catch that silently swallowed setup errors,
which made the UI report success even when the container/service
failed to start.
2026-08-12 01:36:16 -06:00
Mauricio Siu
f12ecc3350
fix: don't cancel schedule deployments running outside the panel process on restart (#5053)
Some checks are pending
Auto PR to main when version changes / create-pr (push) Waiting to run
Build Docker images / build-and-push-cloud-image (push) Waiting to run
Build Docker images / build-and-push-schedule-image (push) Waiting to run
Build Docker images / build-and-push-server-image (push) Waiting to run
Dokploy Docker Build / docker-amd (push) Waiting to run
Dokploy Docker Build / docker-arm (push) Waiting to run
Dokploy Docker Build / combine-manifests (push) Blocked by required conditions
Dokploy Docker Build / generate-release (push) Blocked by required conditions
Dokploy Docker Build / sync-version (push) Blocked by required conditions
autofix.ci / format (push) Waiting to run
Dokploy Monitoring Build / docker-amd (push) Waiting to run
Dokploy Monitoring Build / docker-arm (push) Waiting to run
Dokploy Monitoring Build / combine-manifests (push) Blocked by required conditions
Generate and Sync OpenAPI / Generate OpenAPI and commit to Dokploy repo (push) Waiting to run
Fixes #4986. initCancelDeployments blindly marked every 'running'
deployment as 'cancelled' on boot, including schedule runs whose
actual work (docker exec into another container, or SSH to a remote
host) is decoupled from the Dokploy process and keeps running after
a restart. Now only deployments with no schedule, or schedules of
type dokploy-server (a real child process), get cancelled.

Also resolve any stale 'running' deployment for a schedule when a
new run starts, so restarted panels don't leave ghost 'running' rows
forever.
2026-08-11 21:33:49 -06:00
Mauricio Siu
34c5b688ac
fix: docker cleanup hangs silently on false-positive busy-wait match (#5051)
dockerSafeExec's busy-wait matched any process with "docker <letter>"
anywhere in its argv (e.g. Grafana's --packaging=docker cfg:...),
causing the wait loop to spin forever. Anchor the match to the actual
docker binary (argv[0]) instead, and add a MAX_WAIT ceiling so a
genuinely stuck docker process can't hang cleanup indefinitely either.

Also log failures in cleanupAll's catch instead of swallowing them,
since the scheduled cleanup path only goes through this function.

Fixes #5044
2026-08-11 20:40:24 -06:00
Mauricio Siu
cba6ce9c57 Merge branch 'canary' into feat/scaleway-secret-manager 2026-08-11 20:02:08 -06:00
Narciso E. Núñez Arias
870d592a97
Merge pull request #4584 from andershermansen/fix/upgrade-traefik-3.6.20
Some checks are pending
Auto PR to main when version changes / create-pr (push) Waiting to run
Build Docker images / build-and-push-cloud-image (push) Waiting to run
Build Docker images / build-and-push-schedule-image (push) Waiting to run
Build Docker images / build-and-push-server-image (push) Waiting to run
Dokploy Docker Build / docker-amd (push) Waiting to run
Dokploy Docker Build / docker-arm (push) Waiting to run
Dokploy Docker Build / combine-manifests (push) Blocked by required conditions
Dokploy Docker Build / generate-release (push) Blocked by required conditions
Dokploy Docker Build / sync-version (push) Blocked by required conditions
autofix.ci / format (push) Waiting to run
Dokploy Monitoring Build / docker-amd (push) Waiting to run
Dokploy Monitoring Build / docker-arm (push) Waiting to run
Dokploy Monitoring Build / combine-manifests (push) Blocked by required conditions
Generate and Sync OpenAPI / Generate OpenAPI and commit to Dokploy repo (push) Waiting to run
fix(security): update Traefik from v3.6.7 to v3.6.25
2026-08-11 13:31:54 -04:00
Vyacheslav Scherbinin
5bcaf9dafb Merge remote-tracking branch 'upstream/canary' into feat/domain-enable-disable
# Conflicts:
#	apps/dokploy/drizzle/meta/0182_snapshot.json
#	apps/dokploy/drizzle/meta/_journal.json
2026-08-11 22:59:41 +07:00
Quentin Gillet
f238347ed7 feat(vault): add Scaleway Secret Manager provider
Adds Scaleway Secret Manager as a first-class vault provider alongside
HashiCorp Vault/OpenBao, Infisical, AWS, Doppler and Azure Key Vault.

- New `scaleway` provider type, zod-validated config (region, project ID,
  API secret key, overridable API URL) and migration adding the enum value
- Plain `fetch` client (no new dependency) against the Secret Manager
  v1beta1 REST API: access-by-path for reads, paginated listing for the
  env editor autocomplete, and a connection test
- Refs are `[folder/]name[:field]` — the field selector extracts a key
  from JSON/key-value secrets, like the AWS provider
- Secret key masked in API responses like every other provider credential
- Settings -> Secrets form with region picker, brand icon and reference
  format help
2026-08-11 16:21:32 +01:00
Mauricio Siu
aaf8d7e12f feat(organization): allow setting a default role for new members 2026-08-11 02:21:33 -06:00
Mauricio Siu
c6c259f926 refactor: add icon support for deployments and services in UI components 2026-08-11 02:01:21 -06:00
Mauricio Siu
71521f2711 feat: upgrade to TypeScript 7 and Next.js 16.3 2026-08-11 01:39:09 -06:00
Anders Semb Hermansen
36db6f589a fix(security): update Traefik to v3.6.25 2026-08-11 08:36:36 +02:00
Anders Semb Hermansen
3cefade4a0 Merge remote-tracking branch 'origin/canary' into fix/upgrade-traefik-3.6.20 2026-08-11 08:35:23 +02:00
Vyacheslav Scherbinin
5ceb88bebe fix(compose): regenerate mapping domain labels 2026-08-11 12:29:49 +07:00
Narciso
286938bbbb fix: sort imports in domain.ts (biome) 2026-08-11 00:22:45 -04:00
Narciso
604d9b1004 Merge remote-tracking branch 'origin/canary' into fix/cmdi-domain-servicename 2026-08-11 00:18:31 -04:00
Vyacheslav Scherbinin
67fa8e4104 fix(compose): clean domain labels across services 2026-08-11 11:16:44 +07:00