attempts to have better validation during deploy from template

This commit is contained in:
Raven Scott
2025-11-24 18:26:13 -05:00
parent 4fb97242e8
commit 6c8ad3e9a0
4 changed files with 761 additions and 35 deletions
+9
View File
@@ -354,6 +354,15 @@ swarm.on('connection', (peer) => {
.map(e => {
const name = validation.sanitizeEnvVarName(e.name);
const value = validation.sanitizeEnvVarValue(e.value);
// Additional validation: check if preset value was modified
// Note: This is a basic check - full template validation happens client-side
if (e.preset === true && name) {
// Log warning if preset value appears to be modified
// (We can't fully validate without template, but we can check format)
logger.debug(`Preset env var ${name} being set to: ${value}`);
}
return name && value !== null ? `${name}=${value}` : null;
})
.filter(e => e !== null);