Kubernetes Pods

A pod can contain one or multiple containers, usually one. Kubernetes only recommends to launch multiple containers in a pod, when those containers need to share a volume. For example a syslog-ng container saves log files in a volume, a Splunk Heavy Forwarder container monitors them and sends the log entries to the Splunk Indexer. …

Kubernetes Deployments

You only need a deployment to launch a container in Kubernetes. Deployments tell Kubernetes what container to run by specifying the Docker image name and tag spec: template: spec: containers: – image: when to pull the image from the registry spec: template: spec: containers: imagePullPolicy: If the image is always rebuilt with the same version, …

Working with Kubernetes in enterprise settings

How many Kubernetes clusters do I need? Clusters First, we want to separate the non-production and production environments: Create two Kubernetes clusters for every application or application suite. One for pre-production and one for production. Namespaces We also want to separate each non-production and production like environment. Kubernetes offers namespaces to create segregated areas, resources …

Kubernetes Services

Kubernetes Services route traffic across a set of pods. The service specifies how deployments (applications) are exposed to each other or the outside world. Service types The service type specifies how the deployment will be exposed ClusterIP The ClusterIP service is only visible within the cluster. To expose the pod to other services in the …

Docker Swarm volumes

Containers are ephemeral. Containers live entirely in memory, so even if the container is set up with automatic restart, the new container will not have access to the data created inside of the old container. To save persistent data of Docker containers we need to create volumes that live outside of the ephemeral containers. Don’t …

Kubernetes volumes

To understand the types of available volumes read the official Kubernetes documentation on Volumes The official documentation on Kubernetes Persistent Volume and Persistent Volume Claim is at Persistent Volumes Migrating to CSI drivers from in-tree plugins Kubernetes moves away from in-tree plugins, that had to be checked into the Kubernetes code repository to out-of-tree volume …

Resources to learn Kubernetes

This is a great five part blog series on Kubernetes and a post on volumes by Sebastian Caceres. I recommend reading it even before the official Kubernetes tutorial to get a great overview of how Kubernetes really works. How does it work? Kubernetes: Episode 1 – Kubernetes general architecture How does it work? Kubernetes: Episode …