-
-
Notifications
You must be signed in to change notification settings - Fork 313
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add support for CRD annotations and labels in kube-derive #1631
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1631 +/- ##
=======================================
+ Coverage 75.3% 75.3% +0.1%
=======================================
Files 82 82
Lines 7346 7371 +25
=======================================
+ Hits 5528 5550 +22
- Misses 1818 1821 +3
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey, thanks for this. I think the general setup is sensible, but have one improvement request for the attribute API, which i think can be nicer.
(Also if you want, when we get it done well, feel free to also do annotation support).
6882a95
to
ecebef3
Compare
I rewrote the solution so the values are now passed as a two-string tuple. Also added the annotation support. |
ecebef3
to
719fdf5
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
very nice. tests and doc look much clearer now. thanks for taking the time to do this.
Signed-off-by: Andreas Metsälä <[email protected]>
719fdf5
to
7d0f590
Compare
This PR adds support for setting annotations and labels on kube-derive generated CRDs.
Motivation
Writing Cluster API providers requires setting specific labels on the CRD: https://cluster-api.sigs.k8s.io/developer/providers/contracts#api-version-labels
Solution
New
annotation
andlabel
fields are added to kube-derive which can take a tuple of two strings as an argument.