-
Notifications
You must be signed in to change notification settings - Fork 558
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
Removing Dependency on IMDS, allowing hostNetwork: true
to be removed
#681
Removing Dependency on IMDS, allowing hostNetwork: true
to be removed
#681
Conversation
Hi @jonathanrainer. Thanks for your PR. I'm waiting for a kubernetes-sigs 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. |
hostNetwork: true
to be removehostNetwork: true
to be removed
/ok-to-test |
96c0b7a
to
d5db2a9
Compare
e2e auto-run tests looking good |
/lgtm |
@Ashley-wenyizha: changing LGTM is restricted to collaborators In response to this:
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. |
/retest |
/retest |
1 similar comment
/retest |
7612913
to
e8cf834
Compare
hack/values_ekstcl.yaml
Outdated
node: | ||
logLevel: 5 | ||
serviceAccount: | ||
controller: |
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.
with latest helm chart, should be controller.serviceAccount not serviceAccount.controller similar to the EBS one.
https://github.com/kubernetes-sigs/aws-ebs-csi-driver/blob/master/hack/values_eksctl.yaml
Also the enalbeVolumeSnapshot line can be removed
Once kubernetes/test-infra#26573 merges we can see if the CI passes |
ffe21d3
to
07f1ca9
Compare
@wongma7 Had a look through this and I think the majority of the errors are because of service accounts that don't have permissions, I'll try and have a look into it but if you could too that would be great |
@jonathanrainer need to add https://github.com/kubernetes-sigs/aws-ebs-csi-driver/blob/master/charts/aws-ebs-csi-driver/templates/controller.yaml#L93-L96 to the template (and kustomize , by running
this is good in sense that the CI test is working as intended...metadata is not available so it's looking for nodeName |
Thanks that's really useful to know I can pull the pod logs out of prow now, pretty sure I'll be much faster/self-sufficient in future! |
@wongma7 Yay it all passed, thanks a lot for your help |
THX lgtm, could you squash the commits and i'll drop the "real" lgtm. Ideally one commit with vendor changes and one commit with the rest, but putting it all together in 1 commit is fine as well. |
… back to k8s API To do this we put the IMDS requirements behind a MetadataProvider object that can also call to k8s if required. This has also beefed up the E2E tests to cover EKS properly and added unit tests around the new changes.
a4740d6
to
a17603b
Compare
@wongma7 All squashed and ready to go |
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: jonathanrainer, wongma7 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 |
Is this a bug fix or adding new feature?
This PR is a fix that allows the driver to keep functioning even in situations where IMDS is not available. It does this by falling back to the Kubernetes API to get the required information if it cannot get it from the EC2Metadata Service.
What is this PR about? / Why do we need it?
This PR is in response to #313, and will allow the driver to function in environments that do not have access to IMDS. The code was based heavily on kubernetes-sigs/aws-ebs-csi-driver#907, but refactored slightly to use a provider pattern for the metadata and factor out each part into their own file to allow more ease of testing.
What testing is done?
Have written additional unit tests to cover the change but need some help running the E2E tests as running them on my local setup has been fraught with problems. Any guidance on this (can we run them on the usual E2E infrastructure as a one off perhaps?) would be greatly appreciated.
fixes #313