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

KVM minikube cluster on Packet #187

Merged
merged 3 commits into from
Oct 1, 2018
Merged

KVM minikube cluster on Packet #187

merged 3 commits into from
Oct 1, 2018

Conversation

alexsomesan
Copy link
Member

@alexsomesan alexsomesan commented Sep 25, 2018

Currently the acceptance tests on Packet are non-functional because VirtualBox fails to install correctly.

This change adapts the acceptance test infrastructure on Packer to run the a K8S cluster on KVM instead of using VirtualBox.

@terraform-providers/ecosystem

@ghost ghost added the size/S label Sep 25, 2018
@alexsomesan alexsomesan changed the title Bare-metal minikube cluster on Packer Bare-metal minikube cluster on Packet Sep 25, 2018
Copy link
Member

@radeksimko radeksimko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks reasonable to me, but which K8S versions does this change limit us to, out of interest?

I remember I used VBox because that was the only way to get 1.6.x working.

I'm happy for us to abandon 1.6, or any unmaintained version for that purpose. I do want to see it mentioned in the PR though, and ensure that it's intentional 😉

@alexsomesan alexsomesan changed the title Bare-metal minikube cluster on Packet KVM minikube cluster on Packet Sep 27, 2018
@alexsomesan
Copy link
Member Author

That makes sense, Radek. Thanks for the very good points made.

I didn't initially intend to exclude version 1.6.x from the suite, but as it turns out, regardless of the underlying virtualisation used, 1.6 isn't really supported anymore by recent minikube versions. At least not out of the box, without hacks.

I came back to these changes and resorted to use KVM instead of VirtualBox. The reason for it is similar - it installs directly from the official distro repository which is supposed to be more robust. Also, it doesn't require kernel modules to be built at install time, which save some boot time and also increases robustness of the whole provisioning.

Let me know what you think if this approach.

Copy link
Member

@radeksimko radeksimko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, that makes sense. 👍

Just to confirm - as of now we're limited to 1.7.x+, right?

KUBECTL_VERSION=$(curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt)
curl -LO https://storage.googleapis.com/kubernetes-release/release/${KUBECTL_VERSION}/bin/linux/amd64/kubectl \
&& chmod +x kubectl && mv kubectl /usr/local/bin/
&& chmod a+x kubectl && mv kubectl /usr/local/bin/
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 for explicitness, thanks

minikube version
minikube config set WantReportErrorPrompt false
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nitpick: Can you explain what this does in a brief comment above the line, please?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If minikube fails for any reason and this is set to true (the default) then it will show an interactive prompt asking the user to confirm that minikube can phone back home with diagnostic information. It's undesirable to have this happen in an automated environment like CI.

The actual prompt message is this

================================================================================
An error has occurred. Would you like to opt in to sending anonymized crash
information to minikube to help prevent future errors?
To opt out of these messages, run the command:
	minikube config set WantReportErrorPrompt false
================================================================================

@alexsomesan
Copy link
Member Author

Yes, we're limited to 1.7.x on platforms that still support it (like minikube).
GKE for one, only supports 1.9.x and 1.10.x as of now.

@ghost ghost added size/M and removed size/S labels Oct 1, 2018
@alexsomesan alexsomesan merged commit d6612e5 into master Oct 1, 2018
@ghost ghost locked and limited conversation to collaborators Apr 21, 2020
@aareet aareet deleted the fix-packet-infra branch June 16, 2020 22:28
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants