-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
📖 Metadata propagation docs #5426
📖 Metadata propagation docs #5426
Conversation
cc @sbueringer |
/retitle 📖 Metadata propagation docs |
0cbac1d
to
dfc2b26
Compare
docs/book/src/developer/architecture/controllers/metadata-propagation.md
Show resolved
Hide resolved
dfc2b26
to
66ea9c2
Compare
66ea9c2
to
8cef9f1
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.
one nit, otherwise lgtm from my side. Thx for taking care of this!
|
||
## KubeadmControlPlane | ||
Top-level labels and annotations do not propagate at all. | ||
MachineTemplate labels and annotations propagate to Machines, InfraMachines and BootstrapConfig. |
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.
MachineTemplate labels and annotations propagate to Machines, InfraMachines and BootstrapConfig. | |
MachineTemplate labels and annotations propagate to Machines, InfraMachines and BootstrapConfigs. |
nit (plural like the others in the list)
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.
(similar below for MachineSets)
8cef9f1
to
5da280d
Compare
/lgtm |
/lgtm |
Top-level labels and annotations do not propagate at all. | ||
MachineTemplate labels and annotations propagate to Machines, InfraMachines and BootstrapConfigs. | ||
|
||
- .labels => | ||
- .annotations => | ||
- .spec.machineTemplate.metadata.labels => Machine.labels, InfraMachine.labels, BootstrapConfig.labels | ||
- .spec.machineTemplate.metadata.annotations => Machine.annotations, InfraMachine.annotations, BootstrapConfig.annotations |
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.
Might be we should match explanation with the rule in => notation
Top-level labels and annotations do not propagate at all. | |
MachineTemplate labels and annotations propagate to Machines, InfraMachines and BootstrapConfigs. | |
- .labels => | |
- .annotations => | |
- .spec.machineTemplate.metadata.labels => Machine.labels, InfraMachine.labels, BootstrapConfig.labels | |
- .spec.machineTemplate.metadata.annotations => Machine.annotations, InfraMachine.annotations, BootstrapConfig.annotations | |
Top-level labels and annotations do not propagate at all. | |
- `KubeadmControlPlane.labels` => (not propagated) | |
- `KubeadmControlPlane.annotations` => (not propagated) | |
MachineTemplate labels and annotations propagate to Machines, InfraMachines and BootstrapConfigs. | |
- `KubeadmControlPlane.spec.machineTemplate.metadata.labels` => `Machine.labels`, `InfraMachine.labels`, `BootstrapConfig.labels` | |
- `KubeadmControlPlane.spec.machineTemplate.metadata.annotations` => `Machine.annotations`, `InfraMachine.annotations`, `BootstrapConfig.annotations` |
5da280d
to
4dca31c
Compare
/lgtm |
# Metadata propagation | ||
Cluster API controllers implement consistent metadata (labels & annotations) propagation across the core API resources. | ||
This behaviour tries to be consistent with kubernetes apps/v1 Deployment and ReplicaSet. | ||
New providers should behave accordingly fitting within the following pattern: |
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.
I'm ok merging this as-is, have we considered in alternative to add these details to each respective page?
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.
As a recurring topic that crosses multiple CRDs I find it useful to have it all in one single place but I'm fine either way, happy to hear others thoughts.
/approve |
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.
/lgtm
/approve
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: fabriziopandini, vincepri The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
What this PR does / why we need it:
Add metadata propagation docs
Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close the issue(s) when PR gets merged):Fixes #5397