Skip to content

No way to remove inherited deny entries when extending a template #122

@yimsk

Description

@yimsk

When a config extends a template (e.g. code), all deny* entries are merged additively. There is no way to remove a deny entry inherited from the parent.

Example: The code template includes "~/.docker/**" in denyRead to protect registry credentials. If a user needs Docker config access (e.g. for proxy settings or credential helper references), there's no way to remove that entry while still inheriting the rest of the template.

The only workaround today is to stop using extends and duplicate the entire template with the entry removed.

Proposal: Support a negation prefix (e.g. !) in deny fields to remove inherited entries:

{
  "extends": "code",
  "filesystem": {
    "denyRead": ["!~/.docker/**"]
  }
}

This would apply consistently to all deny fields: denyRead, denyWrite, command.deny, and deniedDomains.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions