Containers


These are some resources grouped together to make life easy for me to follow up with containers and orchestration technologies. So have fun ^_^.

Docker

Docker is the most popular engine that support linux container and let you manage linux conatiner easy.

Usefull commands:

Remove all stopped containers:

sudo docker rm $(sudo docker ps -a -q)

Remove all untagged images:

sudo docker rmi $(sudo docker images | grep "^<none>" | awk "{print $3}")

Docker Compose is for running and configuring multi-containers.

Docker stats API released on docker 1.5. It is a CLI command that will stream live resource usage information (such as CPU, memory, network IO and block IO) for your containers.

Docker Logentries Container provides out of the box dashboards, alerts and tags for your stats API data per container.

CoreOS

It is an operating system focused on containers and designed for clustering. It has autoupdate to the system.

This is why CoreOS seperated from Docker:

When Docker was first introduced to us in early 2013, the idea of a “standard container” was striking and immediately attractive: a simple component, a composable unit, that could be used in a variety of systems. The Docker repository included a manifesto of what a standard container should be. This was a rally cry to the industry, and we quickly followed. Brandon Philips, co-founder/CTO of CoreOS, became a top Docker contributor, and now serves on the Docker governance board. CoreOS is one of the most widely used platforms for Docker containers, and ships releases to the community hours after they happen upstream. We thought Docker would become a simple unit that we can all agree on.

Unfortunately, a simple re-usable component is not how things are playing out. Docker now is building tools for launching cloud servers, systems for clustering, and a wide range of functions: building images, running images, uploading, downloading, and eventually even overlay networking, all compiled into one monolithic binary running primarily as root on your server. The standard container manifesto was removed. We should stop talking about Docker containers, and start talking about the Docker Platform. It is not becoming the simple composable building block we had envisioned.

rkt is an alternative to the Docker runtime, designed for server environments with the most rigorous security and production requirements. rkt is oriented around the App Container specification, a new set of simple and open specifications for a portable container format.

etcd is a highly-available key value store for shared configuration and service discovery. Incorporated with Kubernetes.

Raft algorithm offers a generic way to distribute a state machine across a cluster of computing systems, ensuring that each node in the cluster agrees upon the same series of state transitions. It is used in etcd to distribute the state of clusters. Be sure to watch this. An Introduction to Raft (CoreOS Fest 2015)

flannel is an overlay network that gives a subnet to each machine for use with Kubernetes.

Clair is a tool to monitor the security of containers,

Orchestration of containers

Kubernetes vs Mesos vs Fleet vs Docker Swarm:

Mesos and Kubernetes are largely aimed at solving similar problems of running clustered applications, they have different histories and different approaches to solving the problem.

Mesos focuses its energy on very generic scheduling, and plugging in multiple different schedulers. This means that it enables systems like Hadoop and Marathon to co-exist in the same scheduling environment. Mesos is less focused on running containers. Mesos existed prior to widespread interest in containers and has been re-factored in parts to support containers.

In contrast, Kubernetes was designed from the ground up to be an environment for building distributed applications from containers. It includes primitives for replication and service discovery as core primitives, where-as such things are added via frameworks in Mesos. The primary goal of Kubernetes is a system for building, running and managing distributed systems.

Fleet is a lower-level task distributor. It is useful for bootstrapping a cluster system, for example CoreOS uses it to distribute the kubernetes agents and binaries out to the machines in a cluster in order to turn-up a kubernetes cluster. It is not really intended to solve the same distributed application development problems, think of it more like systemd/init.d/upstart for your cluster. It’s not required if you run kubernetes, you can use other tools (e.g. Salt, Puppet, Ansible, Chef, …) to accomplish the same binary distribution.

Swarm is an effort by Docker to extend the existing Docker API to make a cluster of machines look like a single Docker API. Fundamentally, our experience at Google and elsewhere indicates that the node API is insufficient for a cluster API

Other great articles:

Open Container Project

OCP will be housed under the Linux Foundation. It is a nonprofit organization that is “chartered to establish common standards for software containers.” Docker is donating both the draft specifications and the code around its image format and runtime engine to get the project started. IT will hopefully solve the conflict of and different standard for linux container standards.

The goal is to not bound to higher level constructs such as a particular client or orchestration stack not tightly associated with any particular commercial vendor or project portable across a wide variety of operating systems, hardware, CPU architectures, public clouds, etc.

Container Specifications:

References:

comments powered by Disqus