Skip to content

feat: add container resource breakdown to monitoring#4571

Open
agentHits wants to merge 1 commit into
Dokploy:canaryfrom
agentHits:feat/monitoring-resource-breakdown
Open

feat: add container resource breakdown to monitoring#4571
agentHits wants to merge 1 commit into
Dokploy:canaryfrom
agentHits:feat/monitoring-resource-breakdown

Conversation

@agentHits

Copy link
Copy Markdown

What is this PR about?

This PR adds a self-hosted Resource Usage breakdown to the Monitoring page. It shows the current CPU, memory, disk size, disk I/O, and network I/O usage per running Docker container, and lets users expand a container row to inspect its top processes by CPU/memory usage.

The feature is only exposed for the Dokploy container monitoring view and reuses the existing monitoring:read permission. Docker container IDs are validated before running docker top, and the Cloud version keeps the same restricted behavior as the existing monitoring endpoints.

Checklist

Before submitting this PR, please make sure that:

  • You created a dedicated branch based on the canary branch.
  • You have read the suggestions in the CONTRIBUTING.md file https://github.com/Dokploy/dokploy/blob/canary/CONTRIBUTING.md#pull-request
  • You have tested this PR in your local instance. If you have not tested it yet, please do so before submitting. This helps avoid wasting maintainers' time reviewing code that has not been verified by you.

Testing

  • corepack pnpm --dir apps/dokploy exec vitest --config __test__/vitest.config.ts __test__/monitoring/container-resource-usage.test.ts --run
  • corepack pnpm exec biome check apps/dokploy/__test__/monitoring/container-resource-usage.test.ts apps/dokploy/components/dashboard/monitoring/container-resource-usage/container-resource-usage.tsx apps/dokploy/components/dashboard/monitoring/container-resource-usage/utils.ts apps/dokploy/components/dashboard/monitoring/free/container/show-free-container-monitoring.tsx apps/dokploy/server/api/routers/server.ts packages/server/src/services/docker.ts
  • corepack pnpm --filter=dokploy run typecheck
  • corepack pnpm --filter=server run typecheck
  • corepack pnpm --filter=dokploy run build-server
  • corepack pnpm --filter=dokploy run build-next
  • corepack pnpm --filter=server run build
  • Tested locally at http://localhost:3000/dashboard/monitoring with the Resource Usage table expanded and container process drill-down verified.

Issues related (if applicable)

N/A

Screenshots (if applicable)

Resource Usage breakdown

@agentHits agentHits requested a review from Siumauricio as a code owner June 7, 2026 17:03
@dosubot dosubot Bot added size:XL This PR changes 500-999 lines, ignoring generated files. enhancement New feature or request labels Jun 7, 2026
@agentHits

Copy link
Copy Markdown
Author
image I need all this because I can’t figure out which container or which service is causing such heavy loads that my VPS is freezing. Therefore, I would like to see this moment, if I have any such loads and loads, I would like to receive a notification in Telegram that a certain container is starting to heavily load my VPS, that it stops responding to me.

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:XL This PR changes 500-999 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant