download kubectl and put it in ~/bin/kubectl #568

Closed
dustinkirkland opened this Issue Jan 13, 2017 · 4 comments

Comments

Projects
None yet
3 participants

It's great that the kubernetes bundle downloads kubectl for you. It should put it in ~/bin/ though, rather than just in ~.

More importantly, there should be a kubectl snap. But that's a separate issue :-)

cmars commented Jan 13, 2017

The spell should also put the config in ~/.kube/config, so you don't have to type --kubeconfig ~/.kube/config.conjure-up every time. That's too tedious.

I think some care needs to be taken though. If the user has an existing kubectl in ~/bin, or an existing ~/.kube/config, the spell really should prompt whether to overwrite these files. Think of established k8s devsusers that want to try conjure-up... you don't want to clobber their existing tools & config!

Alternatively, the spell could write the kubectl and config to a conjure-up specific directory (~/.local/share/conjure-up/kubernetes-core), and provide a shell wrapper (~/bin/kubectl-conjureup ?) that uses them without stomping on a user's existing k8s tools.

Contributor

battlemidget commented Jan 13, 2017

Reason we dont overwrite ~/.kube/config is that someone may have an existing cluster and we didn't want to step on that.

We could potentionally name the config differently and provide a wrapper script that calls kubectl with the correct config.

@battlemidget battlemidget referenced this issue in conjure-up/spells Jan 17, 2017

Closed

[kubernetes] put kubectl in $HOME/bin #33

Contributor

battlemidget commented Jan 30, 2017

For @cmars comment @marcoceppi has provided this gist https://gist.github.com/marcoceppi/e74c10178d1b730a36debc1f1622b2ce that we'll get worked into the spells

@battlemidget battlemidget modified the milestone: 2.1.0 Jan 30, 2017

@battlemidget battlemidget self-assigned this Feb 6, 2017

Contributor

battlemidget commented Feb 16, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment