Last modified January 2, 2017
As your Giant Swarm cluster offers you a fully-managed Kubernetes, the fundamentals you need are basically concluded by the userside documentation of Kubernetes. We have compiled a list of the best resources to get you started fast.
Official Kubernetes Documentation
The first and most important source to enquire should be the official Kubernetes documentation. And as the administration side is mostly taken care of by Giant Swarm, we recommend focussing on the User Guide including the Kubernetes 101 and 201.
Pods are the smallest deployable units of computing that can be created and managed in Kubernetes. They contain one or more containers that run inside the pod as if they were running on a single host.
Labels & Selectors
Labels are key/value pairs that can be attached to objects, such as pods, but also any other object in Kubernetes, even nodes. They should be used to specify identifying attributes of objects that are meaningful and relevant to users. You can then use Selectors to select single or groups of objects.
Deployments are a declarative way of defining the deployment of pods onto the cluster. They manage replication as well as updates of these pods and keep an audit log of all changes.
Services work by defining a logical set of pods and a policy by which to access them. The selection of pods is based on label selectors. In case you select multiple pods, the service automatically takes care of load balancing and assigns them a single internal service IP.
An Ingress is a collection of rules that allow inbound connections from outside the cluster to reach the cluster services. It can be configured to give services externally-reachable URLs, load balance traffic, terminate SSL, offer name based virtual hosting etc.
Secrets & ConfigMaps
There are two primitives for keeping configuration out of your containers. The first is Secrets, which as the name suggest is for storing sensitive information. The second one is ConfigMaps, which you can use for storing general configuration. The two are quite similar in usage and support a variety of use cases.
Unlike the typical pod that you use for long-running processes, jobs let you manage pods that are supposed to terminate and not be restarted. A job creates one or more pods and ensures a specified number of them terminate with success.
A daemon set ensures that an instance of a specific pod is running on all (or a selection of) nodes in a cluster. It creates pods on each added node and garbage collects pods when nodes are removed from the cluster.
With namespaces you can split up your cluster into smaller separate environments. These environments are separate in terms of Kubernetes objects that they contain, but by default do not completely isolate from the rest of the cluster.
Giant Swarm clusters come with KubeDNS installed by default. You can use DNS to discover services and communicate between them.
Useful Tools and Content
There are some useful tools and content out there that help you with get to know Kubernetes.
- The Kubernetes Blog is a good resource for reading up on new features, examples, and user stories around Kubernetes.
- Kompose is a tool to move from
- Helm is a package manager for Kubernetes that helps you deploy common applications to your cluster.
Useful Blog Posts
We have also written some more detailed out blog posts about the basic Kubernetes concepts and use cases for them.
- Understanding Basic Kubernetes Concepts I - An Introduction To Pods, Labels, and Replicas
- Understanding Basic Kubernetes Concepts II - Using Deployments To Manage Your Services Declaratively
- Understanding Basic Kubernetes Concepts III - Services Give You Abstraction
- Understanding Basic Kubernetes Concepts IV - Secrets and ConfigMaps
- Understanding Basic Kubernetes Concepts V - Daemon Sets and Jobs
- Getting Started With A Local Kubernetes Environment
For more extensive and deeper information on Kubernetes you should check out the Reference Documentation, which includes among others the API documentation, CLI documentation, and a Glossary with deeper explanations of all resources.