From 08698da0d2e38c95fc769fdd6dd5442ac57c080a Mon Sep 17 00:00:00 2001 From: gavrielc Date: Sat, 9 May 2026 12:09:11 +0300 Subject: [PATCH] fix(cli): decouple package commands from docker build config add/remove-package should only update the DB and restart. Image rebuild is handled by the self-mod approval flow or manually. Co-Authored-By: Claude Opus 4.6 (1M context) --- src/cli/resources/groups.ts | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/cli/resources/groups.ts b/src/cli/resources/groups.ts index 2127e36..68d1b53 100644 --- a/src/cli/resources/groups.ts +++ b/src/cli/resources/groups.ts @@ -1,5 +1,4 @@ import type { McpServerConfig } from '../../container-config.js'; -import { buildAgentGroupImage } from '../../container-runner.js'; import { restartAgentGroupContainers } from '../../container-restart.js'; import { getContainerConfig, @@ -180,10 +179,9 @@ registerResource({ } } - await buildAgentGroupImage(id); restartAgentGroupContainers(id, 'package added via ncl'); - return { added: { apt: apt || null, npm: npm || null } }; + return { added: { apt: apt || null, npm: npm || null }, note: 'Image rebuild required for packages to take effect. Use install_packages from the agent or rebuild manually.' }; }, }, 'config remove-package': { @@ -211,10 +209,9 @@ registerResource({ updateContainerConfigJson(id, 'packages_npm', filtered); } - await buildAgentGroupImage(id); restartAgentGroupContainers(id, 'package removed via ncl'); - return { removed: { apt: apt || null, npm: npm || null } }; + return { removed: { apt: apt || null, npm: npm || null }, note: 'Image rebuild required for package changes to take effect.' }; }, }, },