Skip to content

"priorityStrategy" for rewrite merge secrets #5326

@Aransh

Description

@Aransh

Is your feature request related to a problem? Please describe.
Following up on #2987 and most notably the discussion here - #4894 (comment).
In #4894, @riccardomc introduced the ability to rewrite merge secrets, and set a "priority" array for secret whose keys will take precedent if they are duplicated across the found secrets.
My issue stems from the fact that any secrets in the "priority" array are validated to exist, and as such are mandatory in order for the externalSecret to work.

Describe the solution you'd like
A new "priorityStrategy" field for either "Error" or "Ignore", allowing to opt-in/out of validating the priority secrets exist.
Can set the default value how you see fit, my 2 cents:
While I CAN see value in this causing an error if a secret is missing in some use-cases (for example if there's a secret you want to mandate), I think the "this key is prioritized if it exists" approach makes more sense, at least as the default.

Describe alternatives you've considered
Other solution for me would be requiring all apps create a blank "prioritized" secret (and I'm talking hundreds of apps 😵‍💫), so less user-friendly

Additional context
Opening this as a separate ticket to @riccardomc's request here - #4894 (comment)

Metadata

Metadata

Assignees

Labels

good first issueGood for newcomerskind/featureCategorizes issue or PR as related to a new feature.track/coreCaptures issues that are related to Core controller work

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions