mirror of
https://github.com/Dokploy/dokploy.git
synced 2026-10-23 08:55:25 +00:00
chore(monitoring): address review comments
This commit is contained in:
@@ -192,7 +192,7 @@ const MENU: Menu = {
|
||||
title: "Monitoring",
|
||||
url: "/dashboard/monitoring",
|
||||
icon: BarChartHorizontalBigIcon,
|
||||
// Host stats also need docker.read, which the stats socket requires
|
||||
// Only enabled in non-cloud environments (product decision) and if user has monitoring.read and docker.read
|
||||
isEnabled: ({ isCloud, permissions }) =>
|
||||
!isCloud &&
|
||||
!!permissions?.monitoring.read &&
|
||||
|
||||
@@ -113,9 +113,6 @@ export async function getServerSideProps(
|
||||
user: { id: user.id },
|
||||
session: { activeOrganizationId: session?.activeOrganizationId || "" },
|
||||
};
|
||||
// Host stats come from the docker stats socket, which requires docker.read.
|
||||
// Checked separately because a member's "Access to Docker" is a legacy
|
||||
// override that only applies when every requested resource has one.
|
||||
const canView =
|
||||
(await hasPermission(permissionCtx, { monitoring: ["read"] })) &&
|
||||
(await hasPermission(permissionCtx, { docker: ["read"] }));
|
||||
|
||||
Reference in New Issue
Block a user