Book Image

The DevOps 2.1 Toolkit: Docker Swarm

By : Viktor Farcic
Book Image

The DevOps 2.1 Toolkit: Docker Swarm

By: Viktor Farcic

Overview of this book

Viktor Farcic's latest book, The DevOps 2.1 Toolkit: Docker Swarm, takes you deeper into one of the major subjects of his international best seller, The DevOps 2.0 Toolkit, and shows you how to successfully integrate Docker Swarm into your DevOps toolset. Viktor shares with you his expert knowledge in all aspects of building, testing, deploying, and monitoring services inside Docker Swarm clusters. You'll go through all the tools required for running a cluster. You'll travel through the whole process with clusters running locally on a laptop. Once you're confident with that outcome, Viktor shows you how to translate your experience to different hosting providers like AWS, Azure, and DigitalOcean. Viktor has updated his DevOps 2.0 framework in this book to use the latest and greatest features and techniques introduced in Docker. We'll go through many practices and even more tools. While there will be a lot of theory, this is a hands-on book. You won't be able to complete it by reading it on the metro on your way to work. You'll have to read this book while in front of the computer and get your hands dirty.
Table of Contents (22 chapters)
Title Page
Credits
About the Author
www.PacktPub.com
Customer Feedback
Preface
11
Embracing Destruction: Pets versus Cattle

Setting up the environment


As in the previous chapters, we'll start with the creation of a cluster we'll use to experiment.

Note

All the commands from this chapter are available in the 07-api.sh (https://gist.github.com/vfarcic/bab7f89f1cbd14f9895a9e0dc7293102) Gist.

Please enter the cloud-provisioning directory where we pulled the repository. Since I might have updated it since the last time you used it, we'll issue a pull. Finally, we'll run the already familiar        script/ dm-swarm.sh that will create a new Swarm cluster:

cd cloud-provisioning

git pull

scripts/dm-swarm.sh

The cluster is up and running.

VMs created with Docker Machine are based on Boot2Docker. It is a lightweight Linux distribution made specifically to run Docker containers. It runs entirely from RAM, is a small 38 MB download, and boots in ~5s. It is based on Tiny Core Linux (http://tinycorelinux.net/). What distinguishes it from more popular Linux distributions is its size. It is stripped down to a bare minimum. This...