Kubernetes
Docs
https://kubernetes.io/docs/setup/pick-right-solution/#table-of-solutions
https://kubernetes.io/docs/reference/kubectl/cheatsheet/
https://kubernetes.io/docs/reference/kubectl/docker-cli-to-kubectl/
Components
https://kubernetes.io/docs/concepts/overview/components/
Creating HA clusters
https://kubernetes.io/docs/setup/production-environment/tools/kubeadm/high-availability/
Objects
https://kubernetes.io/docs/concepts/overview/working-with-objects/kubernetes-objects/
persistent entities All objects in REST API are identified by a Name(such as /api/v1/pods/some-name) and a UID. For non-unique user-provided attributes, Kubernetes provides labels and annotations.
namespaces
multiple virtual clusters backed by the same physical cluster
controllers
ReplicaSet
ReplicaSet is the next-generation Replication Controller. ReplicaSet supports the new set-based selector requirements
Replication Controller
only supports equality-based selector requirements.
Deployment controller
https://kubernetes.io/docs/concepts/workloads/controllers/deployment/ provides declarative updates for Pods and ReplicaSets.
StatefulSet
workload API object used to manage stateful applications. Unlike a Deployment, a StatefulSet maintains a sticky identity for each of their Pods.
DaemonSet
ensures that all (or some) Nodes run a copy of a Pod.
Job & CronJob
https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/
kubectl
https://kubernetes.io/docs/tasks/tools/install-kubectl/
dashboard admin
https://github.com/kubernetes/dashboard/wiki/Access-control#admin-privileges
expose
https://kubernetes.io/docs/tasks/access-application-cluster/port-forward-access-application-cluster/
kubectl expose -h
token
Tutorial
yaml
Release 1.8: apps/v1beta1
-> apps/v1beta2
; 1.9: -> apps/v1
kubectl apply
supports multiple writers to the same object.
syntax
https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.9/ https://kubernetes.io/docs/concepts/overview/object-management-kubectl/declarative-config/
env
https://kubernetes.io/docs/tasks/inject-data-application/define-environment-variable-container/
Command and Arguments
https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/
Description
Docker field name
Kubernetes field name
The command run by the container
Entrypoint
command
The arguments passed to the command
Cmd
args
generator
https://github.com/grafana/tanka
Verbosity
Verbosity
Description
--v=0
Generally useful for this to ALWAYS be visible to an operator.
--v=1
A reasonable default log level if you don’t want verbosity.
--v=2
Useful steady state information about the service and important log messages that may correlate to significant changes in the system. This is the recommended default log level for most systems.
--v=3
Extended information about changes.
--v=4
Debug level verbosity.
--v=6
Display requested resources.
--v=7
Display HTTP request headers.
--v=8
Display HTTP request contents.
minikube
https://github.com/kubernetes/minikube
Bare metal
https://minikube.sigs.k8s.io/docs/start/linux/
KVM
https://github.com/kubernetes/minikube/blob/master/docs/drivers.md#kvm-driver
https://github.com/dhiltgen/docker-machine-kvm https://github.com/docker/machine/releases
kops
https://github.com/kubernetes/kops#linux kubectl for clusters
Create a Cluster
https://kubernetes.io/docs/setup/independent/create-cluster-kubeadm/ https://kubernetes.io/docs/getting-started-guides/scratch/#designing-and-preparing
Persistent Volumes
https://kubernetes.io/docs/concepts/storage/persistent-volumes/
Volume Plugin
ReadWriteOnce
ReadOnlyMany
ReadWriteMany
AWSElasticBlockStore
✓
-
-
AzureFile
✓
✓
✓
AzureDisk
✓
-
-
CephFS
✓
✓
✓
Cinder
✓
-
-
FC
✓
✓
-
FlexVolume
✓
✓
-
Flocker
✓
-
-
GCEPersistentDisk
✓
✓
-
Glusterfs
✓
✓
✓
HostPath
✓
-
-
iSCSI
✓
✓
-
PhotonPersistentDisk
✓
-
-
Quobyte
✓
✓
✓
NFS
✓
✓
✓
RBD
✓
✓
-
VsphereVolume
✓
-
- (works when pods are collocated)
PortworxVolume
✓
-
✓
ScaleIO
✓
✓
-
StorageOS
✓
-
-
helm - package manager
https://docs.helm.sh/using_helm/#quickstart
WebUI
https://github.com/kubernetes-helm/monocular
https://github.com/kubeapps/hub navigate and search Helm Charts.
Hub
Last updated