From c182755591dcad5f6d035a25b5753434c645b7bb Mon Sep 17 00:00:00 2001 From: Mauricio Siu Date: Fri, 8 May 2026 19:22:00 -0600 Subject: [PATCH] feat(templates): support isolated = false opt-out in template.toml Templates using network_mode: host (e.g. cloudflared) can now declare isolated = false in their [config] section to prevent Dokploy from injecting networks into the compose, which would cause a Docker error. Default behavior (isolated = true) is unchanged for all existing templates. Fixes #4366 --- apps/dokploy/server/api/routers/compose.ts | 2 +- packages/server/src/templates/github.ts | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/apps/dokploy/server/api/routers/compose.ts b/apps/dokploy/server/api/routers/compose.ts index 0398b6ba9..254818478 100644 --- a/apps/dokploy/server/api/routers/compose.ts +++ b/apps/dokploy/server/api/routers/compose.ts @@ -640,7 +640,7 @@ export const composeRouter = createTRPCRouter({ name: input.id, sourceType: "raw", appName: appName, - isolatedDeployment: true, + isolatedDeployment: template.config.config?.isolated !== false, }); await addNewService(ctx, compose.composeId); diff --git a/packages/server/src/templates/github.ts b/packages/server/src/templates/github.ts index da697d80c..5b5c4ade8 100644 --- a/packages/server/src/templates/github.ts +++ b/packages/server/src/templates/github.ts @@ -21,6 +21,7 @@ export interface CompleteTemplate { [key: string]: string; }; config: { + isolated?: boolean; domains: Array<{ serviceName: string; port: number;