mirror of
https://github.com/Dokploy/dokploy.git
synced 2026-07-18 12:25:25 +02:00
refactor(cloud): add validation to prevent access to shared resources
This commit is contained in:
@@ -484,7 +484,10 @@ export const settingsRouter = createTRPCRouter({
|
||||
.input(apiReadStatsLogs)
|
||||
.query(({ input }) => {
|
||||
if (IS_CLOUD) {
|
||||
return true;
|
||||
return {
|
||||
data: [],
|
||||
totalCount: 0,
|
||||
};
|
||||
}
|
||||
const rawConfig = readMonitoringConfig();
|
||||
const parsedConfig = parseRawConfig(
|
||||
@@ -499,7 +502,7 @@ export const settingsRouter = createTRPCRouter({
|
||||
}),
|
||||
readStats: adminProcedure.query(() => {
|
||||
if (IS_CLOUD) {
|
||||
return true;
|
||||
return [];
|
||||
}
|
||||
const rawConfig = readMonitoringConfig();
|
||||
const processedLogs = processLogs(rawConfig as string);
|
||||
|
||||
Reference in New Issue
Block a user