Setup a Kubernetes cluster with Juju

A proof of concept Kubernetes setup can be run like this:

root@juju-host:~ juju deploy kubernetes-core

In order to deploy the more production ready Kubernetes setup, download and edit the “bundle.yaml” from the link: https://jaas.ai/charmed-kubernetes

and run:

root@juju-host:~ juju deploy bundle.yaml

In about 30 minutes the Kubernetes cluster will be ready.

To use the “kubectl” tool from the juju client machine,

Create the kubectl config directory.

root@juju-host:~ mkdir -p ~/.kube

Copy the kubeconfig file to the default location.

root@juju-host:~ juju scp kubernetes-master/0:config ~/.kube/config

Install kubectl locally.

root@juju-host:~ snap install kubectl --classic

Query the cluster. ("/snap/bin" might be needed to be added in PATH)

root@juju-host:~ kubectl cluster-info