Skip to content

feat: add status subresource to ConstraintTemplatePodStatus CRD#1

Closed
a7i wants to merge 1 commit into
masterfrom
feat/ct-podstatus-status-subresource
Closed

feat: add status subresource to ConstraintTemplatePodStatus CRD#1
a7i wants to merge 1 commit into
masterfrom
feat/ct-podstatus-status-subresource

Conversation

@a7i

@a7i a7i commented Jul 3, 2026

Copy link
Copy Markdown
Owner

What this PR does / why we need it:

  • Adds +kubebuilder:subresource:status to ConstraintTemplatePodStatus and regenerates the CRD/manifests.
  • Switches the ConstraintTemplate reconciler to write pod status via Status().Update instead of full-object Update.

Separate from open-policy-agent#4596: this changes the write API path to the conventional status subresource. It does not address stale informer cache conflicts on its own; that still needs the retry/refetch logic in open-policy-agent#4596.

Which issue(s) this PR fixes (optional, using fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):

Related to open-policy-agent#4595

Special notes for your reviewer:

Made with Cursor

Declare a Kubernetes status subresource on ConstraintTemplatePodStatus and
switch the ConstraintTemplate reconciler to write pod status via
Status().Update instead of a full-object Update.

This aligns the write path with other Gatekeeper controllers that update
status subresources. It does not replace the stale-cache conflict retry in
open-policy-agent#4596; Status().Update still requires a current resourceVersion.

Signed-off-by: Amir Alavi <amiralavi7@gmail.com>
@a7i

a7i commented Jul 3, 2026

Copy link
Copy Markdown
Owner Author

Superseded by upstream PR.

@a7i a7i closed this Jul 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant