Skip to content
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

K0s ClusterID added to annotations #840

Merged
merged 1 commit into from
Dec 4, 2024
Merged

Conversation

makhov
Copy link
Contributor

@makhov makhov commented Dec 2, 2024

Fixes #683

@makhov makhov requested a review from a team as a code owner December 2, 2024 08:00
@makhov makhov force-pushed the fix-683 branch 2 times, most recently from 4fe6716 to cf99d30 Compare December 2, 2024 09:13
@apedriza
Copy link
Contributor

apedriza commented Dec 2, 2024

How about adding it as a controlplane annotation and not as part of the controlplane status? In general I think that a clusterID is not part of the controlplane state as such, WDYT?

Following annotations definition:

You can use Kubernetes annotations to attach arbitrary non-identifying metadata to objects. Clients such as tools and libraries can retrieve this metadata.

@makhov
Copy link
Contributor Author

makhov commented Dec 3, 2024

Yeah, good point.

@eromanova is it ok, if we add clusterID as annotation to K0smotronControlPlane and K0sControlPlane objects?

@apedriza or should we add the annotation to the Cluster object itself?

@eromanova
Copy link

@makhov Yes, it’s fine if the clusterID is stored in the annotation. What matters is that we can retrieve it from the public API objects, regardless of where the field is located.

@apedriza
Copy link
Contributor

apedriza commented Dec 3, 2024

@apedriza or should we add the annotation to the Cluster object itself?

Yes, good idea 👍

@makhov makhov force-pushed the fix-683 branch 3 times, most recently from 1de35f5 to 4192e9e Compare December 3, 2024 11:58
@makhov makhov changed the title K0s ClusterID added to status K0s ClusterID added to annotations Dec 3, 2024
@makhov makhov force-pushed the fix-683 branch 6 times, most recently from 698c494 to eb3cadd Compare December 3, 2024 14:02
Signed-off-by: Alexey Makhov <amakhov@mirantis.com>
@makhov makhov merged commit e5292d5 into k0sproject:main Dec 4, 2024
38 checks passed
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.

Expose k0s cluster ID in kosmotron API
3 participants