From c93c9c39a21ea9da3bea278fa89c8dc94607a6b1 Mon Sep 17 00:00:00 2001 From: Kris Zyp Date: Wed, 20 May 2026 06:45:24 -0600 Subject: [PATCH 1/2] feat(deploy-component): add install_allow_scripts flag Co-Authored-By: Claude Sonnet 4.6 --- components/operations.js | 4 +++- components/operationsValidation.js | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/components/operations.js b/components/operations.js index 4256af8b2b..ffbf4acc2d 100644 --- a/components/operations.js +++ b/components/operations.js @@ -375,10 +375,11 @@ async function deployComponent(req) { const applicationConfig = { package: req.package }; // Avoid writing an empty `install:` block - if (req.install_command || req.install_timeout) { + if (req.install_command || req.install_timeout || req.install_allow_scripts !== undefined) { applicationConfig.install = { command: req.install_command, timeout: req.install_timeout, + allowInstallScripts: req.install_allow_scripts, }; } await configUtils.addConfig(req.project, applicationConfig); @@ -391,6 +392,7 @@ async function deployComponent(req) { install: { command: req.install_command, timeout: req.install_timeout, + allowInstallScripts: req.install_allow_scripts, }, }); diff --git a/components/operationsValidation.js b/components/operationsValidation.js index bf87c10456..4b49a0391d 100644 --- a/components/operationsValidation.js +++ b/components/operationsValidation.js @@ -239,6 +239,7 @@ function deployComponentValidator(req) { restart: Joi.alternatives().try(Joi.boolean(), Joi.string().valid('rolling')).optional(), install_command: Joi.string().optional(), install_timeout: Joi.number().optional(), + install_allow_scripts: Joi.boolean().optional(), force: Joi.boolean().optional(), }); From ebc5cfea776ca2f85661e2dca8f17f57463a491a Mon Sep 17 00:00:00 2001 From: Kris Zyp Date: Wed, 20 May 2026 06:49:50 -0600 Subject: [PATCH 2/2] feat(add-component): add install_allow_scripts flag (consistent with deploy_component) Co-Authored-By: Claude Sonnet 4.6 --- components/operations.js | 3 ++- components/operationsValidation.js | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/components/operations.js b/components/operations.js index ffbf4acc2d..13a4e90507 100644 --- a/components/operations.js +++ b/components/operations.js @@ -217,7 +217,7 @@ async function addComponent(req) { log.trace(`adding component`); const cfDir = configUtils.getConfigPath(hdbTerms.CONFIG_PARAMS.COMPONENTSROOT); - const { project, install_command, install_timeout } = req; + const { project, install_command, install_timeout, install_allow_scripts } = req; const template = req.template || 'https://github.com/harperdb/application-template'; @@ -230,6 +230,7 @@ async function addComponent(req) { install: { command: install_command, timeout: install_timeout, + allowInstallScripts: install_allow_scripts, }, }); await prepareApplication(application); diff --git a/components/operationsValidation.js b/components/operationsValidation.js index 4b49a0391d..d5d43190f9 100644 --- a/components/operationsValidation.js +++ b/components/operationsValidation.js @@ -184,6 +184,7 @@ function addComponentValidator(req) { template: Joi.string().optional(), install_command: Joi.string().optional(), install_timeout: Joi.number().optional(), + install_allow_scripts: Joi.boolean().optional(), }); return validator.validateBySchema(req, addFuncSchema);