[Feature]: Add `nemoclaw policy add <preset>` command for incremental policy management
Description
When deploying features that need new network access (e.g., Slack bot), the sandbox network policy needs updating. The expected workflow would be:
nemoclaw policy add slack
But the NemoClaw CLI has no policy subcommand — policy management must go through openshell directly, which replaces the entire policy on every set.
Current Workflow
- Manually inspect the 200+ line existing policy YAML
- Manually merge the new preset (e.g.,
presets/slack.yaml) into the existing policy - Apply the complete merged file:
openshell policy set --policy merged.yaml --wait my-assistant
Missing any existing policy in the merge means silently losing that network access.
Proposed Workflow
nemoclaw policy add slack # adds Slack preset to current policy
nemoclaw policy add nvidia_forum # adds forum preset
nemoclaw policy list # shows active policies
nemoclaw policy remove discord # removes Discord preset
The presets already exist at nemoclaw-blueprint/policies/presets/ — they just need a CLI command to apply them incrementally.
Additionally it would be nice to provide more presets while onboarding. Currently i apply the following hack to add this to the install script.
sed -i '/^run_onboard() {$/a\
mkdir -p "$HOME/.nemoclaw/source/nemoclaw-blueprint/policies/presets"\
cp -a /run/scripts/presets/. "$HOME/.nemoclaw/source/nemoclaw-blueprint/policies/presets/"' \
/tmp/nemoclaw-install.sh
bash /tmp/nemoclaw-install.sh
But an Env Var to load a custom folder would keep the presets seperate and a path for custom policies with nemoclaw policy so they dont need to be added to /nemoclaw-blueprint/policies/presets
@nv-ddave , These commands already exist. Does that align with your proposed commands?
nemoclaw <name> policy-add Add a network or filesystem policy preset
nemoclaw <name> policy-list List presets (● = applied)
Closing this since the requested commands already exist.