-
Couldn't load subscription status.
- Fork 2
Description
Description
On the resources Project and Workspace there is a webhook implemented which will add core.openmcp.cloud/created-by annotation to the resource on creation.
The resource then looks like this:
apiVersion: core.openmcp.cloud/v1alpha1
kind: Project
metadata:
annotations:
core.openmcp.cloud/created-by: user@example.comThis is missing for the ManagedControlPlane resource.
Goal
A webhook should add the core.openmcp.cloud/created-by on the ManagedControlPlane resource during CREATION time as well.
Tip
By looking on the implementation in the project-workspace-operator, it is solved like so:
https://github.com/openmcp-project/project-workspace-operator/blob/f534796f239942c7686e3517ddcddee2757f3133/api/core/v1alpha1/common_webhook.go#L41-L49
which will get called here:
https://github.com/openmcp-project/project-workspace-operator/blob/f534796f239942c7686e3517ddcddee2757f3133/api/core/v1alpha1/project_webhook.go#L48
Tasks
- Implement
webhook.CustomDefaulterinterface - ...
Acceptance Criteria
- Code has been reviewed by other team members
- New / changed code is documented
- Unit Tests created for new code or existing Unit Tests updated
- Integration Test Suite updated
- Enduser Documentation updated (if applicable)
- Successful demonstration in Review