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

Correct parsing of guestInfo metadata #762

Merged
merged 1 commit into from Oct 31, 2023

Conversation

zerospiel
Copy link
Contributor

@zerospiel zerospiel commented Sep 15, 2023

What this PR does / why we need it:
Proper handling of encoded network for cloud-init in a VM's guestInfo.metadata

Which issue this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close that issue when PR gets merged): fixes #760

Special notes for your reviewer:

Release note:

Support for `base64` and `gzip+base64` encoding types in the `network` section of cloud-init config

@linux-foundation-easycla
Copy link

linux-foundation-easycla bot commented Sep 15, 2023

CLA Signed

The committers listed above are authorized under a signed CLA.

  • ✅ login: zerospiel / name: Mikhail Morgoev (21992e3)

@k8s-ci-robot k8s-ci-robot added cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Sep 15, 2023
@k8s-ci-robot
Copy link
Contributor

Hi @zerospiel. Thanks for your PR.

I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. and removed cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. labels Sep 15, 2023
* fixed inability to discover a node
  that has encoded network config
* added both possible options for
  network config encodings: b64 and gz+b64
@zerospiel
Copy link
Contributor Author

cc @lubronzhan @sbueringer

@zerospiel
Copy link
Contributor Author

cc @wyike PTAL

@wyike
Copy link
Contributor

wyike commented Oct 26, 2023

/ok-to-test

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Oct 26, 2023
@wyike
Copy link
Contributor

wyike commented Oct 30, 2023

Thanks for your PR!

It looks good to me. I am just curious what mechanism you're using to bootstrap a cluster (cluster api or something else?)and then there is a network.encoding wrote to the cloud init data?

By the way, would you add a release note, thanks!

@zerospiel
Copy link
Contributor Author

@wyike Thanks! I updated the initial comment with the note.

I was using a deeply modified (could be considered as from scratch) version of cluster-api, when a machine's guest info meta had base64-encoded netplan config on purpose. And since that behavior is supported, then why don't use it, right? The codebase though couldn't have been changed because of supporting that "old" behavior in already existing clusters

@wyike
Copy link
Contributor

wyike commented Oct 31, 2023

Thanks for the details!

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Oct 31, 2023
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: wyike, zerospiel

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Oct 31, 2023
@k8s-ci-robot k8s-ci-robot merged commit 81ad960 into kubernetes:master Oct 31, 2023
15 checks passed
@zerospiel zerospiel deleted the fix-network-encoding branch October 31, 2023 10:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Node manager should take on account VM's guestinfo.metadata network.encoding key and value
3 participants