Today I assisted a new Docker Palo Alto Meetup, although it was crowded, I got a good spot and I learnt a few more things about Docker and CoreOS. Yet there were two talks and the second was quite interesting topic, Mesos a cluster resource manager, I did not take too many notes.
In the talk Building infrastructure based on CoreOS and Docker, Damien Metzler from Nuxeo explains how they use CoreOS and Docker, together with some custom tool they developed. Nuxeo plaform provides content managament in an easy an fast way, below are the main points
- Fully open source
- Testing has to be easy and fast
- Provide quick trial
- Provide a software factory to the customer
- Choose models
- Run the app
Basically they run on a container all the applications that from the main dashboard a customer chooses. Interesting the concept
Design your cluster for failure
It turns out they use heavily Java processes that can eat up to 1Gb of memory, and eventually you reach out the max capacity of your bare metal.
CoreOS
Comes with a minimal Linux distribution
- Docker
- etcd (key/value distribution)
- fleet (launch jobs on your cluster)
- systemd (replaces init)
- Active/Passive root partition
I really like the active/passive root partition. You have two partitions for the OS, if a patch is required, you stay with your current partition while upgrading the secondary one, then reboots and runs the new one.
fleet
In order to run a job in the cluster, you use a systemd-like definition that fleet processes.
ectd
Helps to distribute information to the members of the cluster.
- register a service on etcd
- location
- status
Gogeta
Gogeta is a proxy-reverse written in Go. Some ideas:
- manteins the last access time
- the last access key in etcd
- restarts the service if required
- kills the container after inactivity
Why would you use Go?
- easy to use
- etcd channels
- stactic status pages (error, wait)
- first working prototype in one week (while learning go)
- build a static executable (good for containers)
A very useful tip Damien gives, #don’t ever put data on the container , if the container goes down, you loose the data. You can use Elasticsearch and spread your data across the cluster.
In summary, Docker and CoreOS are hot topics together with the set of tools that provide a different way to manage your clusters. Increasingly I see how most of these tools are written in Go, and how its community grews.