mirror of
https://github.com/andwati/dokploy.git
synced 2026-10-18 03:02:56 +00:00
fix: preserve parameter expansion (${VAR:-default}) in .env interpolation
This commit is contained in:
@@ -548,7 +548,7 @@ export const prepareEnvironmentVariablesForFile = (
|
||||
const escapedValue = value
|
||||
.replace(/\\/g, "\\\\")
|
||||
.replace(/"/g, '\\"')
|
||||
.replace(/\$(?!\{[A-Za-z_][A-Za-z0-9_]*\})/g, "\\$");
|
||||
.replace(/\$(?!\{[A-Za-z_][A-Za-z0-9_]*(?::?[-+?][^{}]*)?\})/g, "\\$");
|
||||
return `${key}="${escapedValue}"`;
|
||||
});
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user