open-policy-agent / open-policy-agent/cert-controller
Error updating webhook with certificate
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 109
- Forks
- 49
- Avg merge
- 19h 20m
- Merged PRs (30d)
- 6
Description
Ratify is using cert-controller (v0.8.0) to help maintain the tls cert. This is how we add the rotator: https://github.com/deislabs/ratify/blob/dev/pkg/manager/manager.go#L176
It works fine for most of time, but sometimes the Reconcile could fail unexpected.
The error is like:
time=2024-05-08T05:38:05.435383745Z level=error msg=[cert-rotation] Error updating webhook with certificate error=Operation cannot be fulfilled on providers.externaldata.gatekeeper.sh "ratify-mutation-provider": the object has been modified; please apply your changes to the latest version and try again gvk=externaldata.gatekeeper.sh/v1beta1, Kind=Provider name=ratify-mutation-provider
which thrown at: https://github.com/open-policy-agent/cert-controller/blob/master/pkg/rotator/rotator.go#L838, seems it might update the resource with resourceVersion and creationTimestamp.
Wonder if it's a known issue or something wrong with our usage.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the rotator setup in pkg/manager/manager.go around line 176, then inspect cert-controller's pkg/rotator/rotator.go around line 838 and the reported resourceVersion error. Reproduce or trace the reconciliation failure to determine whether Ratify's usage or cert-controller causes the conflict. Done means the cause is established and a documented or tested resolution is identified.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- infrastructure
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100