Skip to content

Instantly share code, notes, and snippets.

@binario200
Last active August 20, 2018 22:27
Show Gist options
  • Save binario200/38cfe77ecc0ac763ef372292d0f1a834 to your computer and use it in GitHub Desktop.
Save binario200/38cfe77ecc0ac763ef372292d0f1a834 to your computer and use it in GitHub Desktop.
kubernetes how to
apiVersion: kubeadm.k8s.io/v1alpha1
kind: MasterConfiguration
networking:
podSubnet: 10.244.0.0/16
apiServerExtraArgs:
service-node-port-range: 8000-31274

In order to use Kubernetes, you need to create a Kubernetes cluster. This lesson discusses how to do this, and demonstrates setting up a simple cluster with one master and one node using kubeadm. After completing this lesson, you will be able to create a simple Kubernetes cluster that you can deploy applications to.

You can find instructions on various ways of installing Kubernetes here: https://kubernetes.io/docs/setup/

Installation instructions specific to kubeadm can he found here: https://kubernetes.io/docs/setup/independent/create-cluster-kubeadm/

Then run this command referencing kube-config.yml

kubeadm init --config kube-config.yml

Use this command to set up a pod network after initializing the master with kubeadm init:

kubectl apply -f https://raw.githubusercontent.com/coreos/flannel/v0.9.1/Documentation/kube-flannel.yml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment