Skip to content

Conversation

@matheuscscp
Copy link
Member

@matheuscscp matheuscscp commented Jan 19, 2026

This custom stage allows Role and RoleBinding objects to be applied on the same call to ApplyAllStaged even if the impersonated ServiceAccount does not have a ClusterRoleBinding for the cluster-admin ClusterRole (which bypasses the existence check for the Role on the dry-run of the RoleBinding).

@matheuscscp matheuscscp added the enhancement New feature or request label Jan 19, 2026
@matheuscscp matheuscscp added the area/server-side-apply SSA related issues and pull requests label Jan 19, 2026
@matheuscscp
Copy link
Member Author

Supersedes #1073

Copy link

@erikgb erikgb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks great, and I am really looking forward to seeing this in a future FluxCD release.

g, ctx := errgroup.WithContext(ctx)
g.SetLimit(m.concurrency)
for i, object := range objects {
i, object := i, object
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this change unrelated to the purpose of the PR, or have I misunderstood? Maybe do it in a separate PR?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Supersedes #1073

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Gonna leave this comment open for context for future readers

Copy link
Member

@stefanprodan stefanprodan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Signed-off-by: Matheus Pimenta <matheuscscp@gmail.com>
@matheuscscp matheuscscp merged commit 4895944 into main Jan 21, 2026
13 checks passed
@matheuscscp matheuscscp deleted the ssa-custom-stage branch January 21, 2026 10:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/server-side-apply SSA related issues and pull requests enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants