Contents

00 Getting Started

00 Motivation

01 🐳 Docker

00 Understanding Docker

02 šŸŽ± Kubernetes

00 Understanding Kubernetes

03 🦊 GitLab

00 Understanding GitLab

04 šŸ’½ Server

00 Provisoning a Server

Understanding Kubernetes

Why use Kubernetes?

Kubernetes is the industry standard for Container Orchestration. One reason why it is so powerful is its use of declarative instructions. Instead of writing code that gets executed and which creates your cluster state, in Kubernetes you provide manifest files, that specify a state you want your cluster to be in. Kubernetes has the ability to automatically move itself into this state. If you tell Kubernetes to always have two instances of your application running, it will automatically create these instances. If one crashes, it gets deleted and a new one is created to again match the defined state.

As a cluster, can consist of multiple servers, Kubernetes can even handle server outage quite well. Imagine a cluster with three servers which are running and serving an application. Now one of the servers is hit by a power outage; Kubernetes finds that its current state does not meet the required one and distributes the resources from the lost server to the other two. If the server is started again, resources can be moved back.

Further, Kubernetes implements a high level of abstraction. Instead of directly interacting with a technology, you always interact with Kubernetes, which then internally interacts with the technology. You don’t start docker containers, you start Kubernetes pods; you don’t configure a Nginx web server yourself but configure an ingress resource that uses Nginx. This has the advantage that if underlying technology evolves, Kubernetes can simply switch it out, without you having to adjust your Manifests.

This actually happened recently: In the beginning Kubernetes was using the Docker container runtime, then they made the switch to containerd. Still, using Kubernetes didn’t change, that’s why abstraction is useful.

Alternatives to Kubernetes

If you want to look for alternatives, use this or a similar search query. Many of the suggested ā€œalternativesā€ use Docker under the hood (e.g. OpenShift). Keep an eye out for these if you really want something different.

Some current alternatives include:

Read Next

Learn how to deploy an application to the internet using microk8s.

Further Resources

Imprint

Designed & Developed by Jasper Anders