Last modified May 12, 2022
As your Giant Swarm cluster offers you fully-managed Kubernetes, the fundamentals you need are basically summarized by the user side 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 read is the official Kubernetes documentation. Since the administrative side is mostly taken care of by Giant Swarm, we recommend focussing on the task-specific tutorials.
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 and 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 their termination after a specified number of successful completions.
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. They do not completely isolate from the rest of the cluster by default.
Managing and resources for containers
To limit usage of resources like RAM and CPU, Kubernetes offer the resource limits.
Scheduling priority and QoS
Based on how resource limits and resource requests are configured, Kubernetes classifies pods by quality of service and decides which pods are scheduled in the case of unsifficient resources.
Giant Swarm clusters come with CoreDNS 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.