diff --git a/packages/server/src/utils/traefik/application.ts b/packages/server/src/utils/traefik/application.ts index c883ca44d..101574ed5 100644 --- a/packages/server/src/utils/traefik/application.ts +++ b/packages/server/src/utils/traefik/application.ts @@ -218,7 +218,11 @@ export const writeConfigRemote = async ( try { const { DYNAMIC_TRAEFIK_PATH } = paths(true); const configPath = path.join(DYNAMIC_TRAEFIK_PATH, `${appName}.yml`); - await execAsyncRemote(serverId, `echo '${traefikConfig}' > ${configPath}`); + const encoded = encodeBase64(traefikConfig); + await execAsyncRemote( + serverId, + `echo "${encoded}" | base64 -d > "${configPath}"`, + ); } catch (e) { console.error("Error saving the YAML config file:", e); }