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

minikube options #86

Closed
nicks opened this issue Dec 30, 2020 · 7 comments · Fixed by #218
Closed

minikube options #86

nicks opened this issue Dec 30, 2020 · 7 comments · Fixed by #218
Labels
enhancement New feature or request

Comments

@nicks
Copy link
Member

nicks commented Dec 30, 2020

Currently, the ctlptl API lets you pass a complete Kind config: https://pkg.go.dev/github.com/tilt-dev/ctlptl/pkg/api#Cluster

ctlptl then merges the cluster-independent options with a user-supplied Kind config.

We should do something similar with minikube flags, so you can do things like minikube start --vm=true --cni=cilium --kubernetes-version='v1.19.4' --bootstrapper=kubeadm, and ctlptl can ensure your cluster has the right settings. (This is a little tricky, because we want to make sure people aren't setting flags that are incompatible with how ctlptl sets up the cluster, but I think it can be done).

@nicks nicks added the enhancement New feature or request label Dec 30, 2020
@cbcoutinho
Copy link

Minikube supports persisting options to a configuration file (e.g. ~/.minikube/config/config.json) on Linux; however, It appears that ctlptl does not respect this user configuration. It currently creates minikube clusters based on whatever the minikube installed defaults are

@nicks
Copy link
Member Author

nicks commented May 10, 2021

@cbcoutinho Thanks for the report!

One of the design goals of this project is to help infra engineers manage a dev environment for their team, see:
https://github.com/tilt-dev/ctlptl#goals

One of the big complaints we see is that a more junior engineer accidentally sets a personal config that makes their team's app run poorly, and doesn't understand why.

So depending on what particular config we're talking about, this may be deliberate. But if there are particular personal configs you think ctlptl should preserve and don't conflict with this design goal, we're open to talking about it.

@cbcoutinho
Copy link

cbcoutinho commented May 10, 2021

I understand the goals of infrastructure teams regarding (naïve) local environments, At the same time, I don't think it's desirable to deviate too much from the behavior of invoking minikube explicitly and via a wrapper like ctlptl.

My particular local config is meant to match the remote clusters I'm currently working with, which I was surprised that ctlptl had ignored when creating the cluster. I'm sure you could think of much more exotic configurations (e.g. https://minikube.sigs.k8s.io/docs/handbook/filesync/), but those are arguably more advanced features that you should know you need if you decide the use them

{
    "container-runtime": "containerd",
    "driver": "kvm2"
}

@remram44
Copy link

I need this. The ctlptl only allows setting specific flags or --extra-config, but there are many minikube flags that are important for specific setups. For example --ports.

Why not accept any command-line flag in the ctlptl configuration?

@nicks
Copy link
Member Author

nicks commented Apr 13, 2022

@remram44 we do have an API for accepting minikube flags in the YAML configs, see d59471b, would totally accept a PR to add Ports

it's a little bit more complex than just forwarding flags, since we have to reconcile against what ctlptl is doing, and some flags are incompatible with how ctlptl sets it up.

@remram44
Copy link

Like I said, this is only for --extra-config and not any of the numerous other flags, even the harmless (to ctlptl) ones like --ports

@nicks
Copy link
Member Author

nicks commented Apr 15, 2022

ya, that's a fair point

nicks added a commit that referenced this issue Apr 20, 2022
nicks added a commit that referenced this issue Apr 20, 2022
nicks added a commit that referenced this issue Apr 20, 2022
nicks added a commit that referenced this issue Apr 20, 2022
nicks added a commit that referenced this issue Apr 20, 2022
nicks added a commit that referenced this issue Apr 20, 2022
nicks added a commit that referenced this issue Apr 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants