Wednesday, February 04, 2015

Book Review: Orchestrating Docker, by Shrikrishna Holla, PacktPub publishing

I just finished reading a review copy of "Orchestrating Docker" a new book from PacktPub, an excellent work from Shrikrishna Holla.  I found the book to be fairly comprehensive about Docker basics, building images, orchestration and even how to build Docker itself, and how to integrate Docker into OpenStack (Havana release via the nova driver).  The book is also very well written, it's a pleasure to read.

That said I do have some criticisms of the book, but the book is still excellent overall.
What is really strange is that the first chapter starts describing how to install Docker (*), and then jumps straight into how to integrate into DevStack (an all-in-one developer version of OpenStack) followed by how to build Docker from source from within a Docker container.

Whilst most books tend to start saying how to install Docker I prefer always to refer to the excellent online documentation, but I guess it's OK to detail this as long as there is a reference to the latest online documentation.  I'd still tend to put this in an appendix though.

Likewise, and even more so covering how to install Docker under DevStack should really be an appendix and should certainly not be in the first chapter before even covering Docker concepts.
Same remark for building Docker under Docker.
I do actually appreciate the DevStack and Docker building instructions but they should be in appendices, in my view.

OK, despite this curious organization of the books chapters the book is still an excellent read and goes into great detail about Docker basics.  Sometimes it feels like a reference manual specifying some docker CLI options without explanation of the terms used.  I've been using Docker for over a year now, nevertheless I did learn a few very useful tidbits from this section (in particularly the difference between load/save, import/export and also between ADD/COPY in Dockerfiles).

Often the "reference" section details a command-line option as 'exists since version 1.2" or similar.
It would be a good idea to state what is the baseline Docker version which is being documented as Docker is moving fast, Docker 1.5 should be out this week.

The book is very complete in the examples provided.  Whilst I've not tested all the examples they seem to make sense and exercise very many of Dockers capabilities of the docker client, the daemon, the REST api, interacting with Docker hub or a private registry, building images, linking containers and so on.

Chapter 3 covers setting resource limits (CPU share, memory usage, disk usage), mounting and sharing volumes,  choosing storage drivers, network configuration, linking containers directly or via the Ambassador pattern.

Chapter 4 covers automation via the REST api, and how to use service discovery with etcd to maintain connectivity across a group of containers dynamically (the Ambassador pattern does this but statically links containers causing the system to malfunction if containers die)

Chapter 4 covers orchestration also, mentioning the newly (December 2014) announced Docker Machine, Docker Swarm and Docker Compose but this was a bit light due to the recent nature of these beta products from Docker.

Chapter 4 terminates discussing security and best practices.
Looks like Chapter 4 could have been split into several chapters, by the way.

Chapter 5 is called "Friends of Docker" and covers Puppet and Chef configuration management tools and the use of apt-cacher.   Dokku is then used as an example (it's a mini-PaaS Heroku clone).

Then there is discussion of high-availability and scaling and examples of using CoreOS/etcd (for service discovery) and Fleet.

Overall this is an excellent book with lots of very useful well written content and is possibly the best Docker book out there right now.  I recommend it.

[Conference -] Developing Micro-services on Kubernetes

In April I had the chance to present at , first in Warsaw on Apr 24th, and then in Wroclaw ("wroslof" was my best at...