-
Notifications
You must be signed in to change notification settings - Fork 39.9k
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
Determine system model to get credentials for windows nodes #80764
Conversation
Hi @liyanhui1228. 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 Once the patch is verified, the new status will be reflected by the 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. |
/assign @yujuhong |
/ok-to-test Could you add a release note? |
Looks like the test failures are related to this. Not sure why it didn't pick up those fixes. |
Looks good! |
/lgtm |
var name string | ||
|
||
if runtime.GOOS == "windows" { | ||
data, err := exec.Command("wmic", "computersystem", "get", "model").Output() |
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.
/cc @pjh
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 checked with a couple team members and they approved this approach. There's a small chance the result will be different in a shielded VM (with UEFI firmware instead of BIOS) - I'll test it out and will let you know if there's a difference (but don't block merge on this).
/retest |
1 similar comment
/retest |
/assign @dchen1107 |
/lgtm |
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: dchen1107, liyanhui1228 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 |
/retest Review the full test history for this PR. Silence the bot with an |
What type of PR is this?
What this PR does / why we need it:
In kubernetes, we get credentials from the metadata server on GCE VMs:
https://github.com/kubernetes/kubernetes/blob/v1.15.0-alpha.2/pkg/credentialprovider/gcp/metadata.go
The credentials are used to pull container images.
But it checks whether it's running on GCE VM by looking at a Linux specific file, which not works on Windows. This PR added the check for Windows node.