18 Mar 2016 in Series: Docker Overview, Docker

Docker Overview, Part One

In my last miniseries, we gave an overview of CoreOS. In this miniseries, I want to take a look at Docker. In this post we’ll look at why it’s special and how it’s built. We’ll start at the beginning, so don’t worry if you’re totally new to this.

Docker is an open source project that makes easier packaging of applications inside containers by providing an additional layer of abstraction and automation of operating-system-level virtualization on Linux.

Containers themselves are just an abstraction over Linux cgroups, which are a lower level kernel construct for jailing and limiting the resources of a process and its children.

Docker was using LinuX Containers (LXC) in the beginning, but then switched to runC, formerly known as libcontainer. runC runs in the same operating system as its host. This allows it to share a lot of the host operating system resources, such as RAM, CPU, networking, and so on.

Read More
15 Mar 2016 in Trip Report, Kubernetes, KubeCon

KubeCon Trip Report

KubeCon is the Kubernetes community conference, in its second year of running now. I had the pleasure of attending KubeCon in London last week, and I came away from it an even bigger fan of Kubernetes than I already was.

I was impressed to find out that less than two years after the first Kubernetes release, there are already over 1,200 new GitHub projects using Kubernetes. What’s even more exciting is the news that Kubernetes has moved to the Cloud Native Computing Foundation.

In this post, I’ll share my experience of the event and cover the stuff I learned.

Read More
11 Mar 2016 in Series: Fleet on CoreOS, Fleet, CoreOS

Fleet on CoreOS, Part One

Servers crash all the time. But it is important to make sure applications, and hence the business, doesn’t suffer. This is why service availability is one of biggest concerns for operational engineers deploying applications in the cloud.

Fleet—a CoreOS tool—solves this problem and frees you from worry by automatically routing application execution to healthy nodes.

So, how does this work?

How does Fleet know if a node is down? How does the rerouting happen?

We covered this in detail in a previous post. But if you’re in a hurry, I will recap.

Each node in a CoreOS cluster runs the fleet daemon, which keeps a tab on the node’s health and is responsible for communicating with other nodes. The daemons coordinate to elect a leader during cluster startup, or when the current leader fails. The leader schedules new services on the nodes whenever a new service request is submitted to the cluster, or when a node goes down taking services with it.

In this miniseries, we’ll get some services up-and-running on a cluster, then take down a node to see how fleet reshuffles things. We’ll then move on and take a closer look at some additional fleet functionality.

Read More
4 Mar 2016 in Series: Connecting Containers, Docker, Overview

Connecting Docker Containers, Part Two

This post is part two of a miniseries looking at how to connect Docker containers.

In part one, we looked at the bridge network driver that allows us to connect containers that all live on the same Docker host. Specifically, we looked at three basic, older uses of this network driver: port exposure, port binding, and linking.

In this post, we’ll look at a more advanced, and up-to-date use of the bridge network driver.

We’ll also look at using the overlay network driver for connecting Docker containers across multiple hosts.

User-Defined Networks

Docker 1.9.0 was released in early November 2015 and shipped with some exciting new networking features. With these changes, now, for two containers to communicate, all that is required is to place them in the same network or sub-network.

Let’s demonstrate that.

Read More
26 Feb 2016 in Series: Connecting Containers, Docker, Overview

Connecting Docker Containers, Part One

Docker containers are self-contained, isolated environments. However, they’re often only useful if they can talk to each other.

There are many ways to connect containers. And we won’t attempt to cover them all. But in this miniseries, we will look at some common ways.

This topic seems elementary, but grasping these techniques and the underlying design concepts is important for working with Docker.

Understanding this topic will:

  • Help developers and ops people explore the broad spectrum of container deployment choices
  • Let developers and ops people to embark more confidently with a microservice design architecture
  • Empower developers and ops people to better orchestrate more complex distributed applications

Fortunately, the large number of connection options for containers enables a broad range of approaches, giving us the flexibility to choose an architecture that suits the needs of any application.

In this post, we'll look at three of the older, more basic ways of connecting Docker containers. Using this knowledge and experience as a foundation, we'll then move on to two newer, easier, more powerful ways in the next post.

Read More