万本电子书0元读

万本电子书0元读

顶部广告

Docker Orchestration电子书

售       价:¥

2人正在读 | 0人评论 9.8

作       者:Randall Smith

出  版  社:Packt Publishing

出版时间:2017-01-01

字       数:346.9万

所属分类: 进口书 > 外文原版书 > 电脑/网络

温馨提示:数字商品不支持退换货,不提供源文件,不支持导出打印

为你推荐

  • 读书简介
  • 目录
  • 累计评论(0条)
  • 读书简介
  • 目录
  • 累计评论(0条)
A concise, fast-paced guide to orchestrating and deploying scalable services with Docker About This Book Explore the new features added to the core Docker Engine to make multi-container orchestration easy Leverage tools such as Docker Machine, Swarm, Compose, and third-party tools such as Kubernetes, Mesosphere, and CoreOS to orchestrate containers Use Docker Compose with Swarm and apply rolling updates for zero downtime deployments Who This Book Is For This book is aimed at Sysadmins and DevOps engineers who know what Docker does and are now looking to manage multiple containers on multiple hosts using the orchestration feature. What You Will Learn Build scalable, reliable services with Docker See how to manage a service in Docker using Docker Swarm, Kubernetes, and Mesosphere Discover simpler orchestration tools such as CoreOS/Fleet and Rancher Cattle Understand cluster-wide logging, system monitoring, and troubleshooting Build, test, and deploy containers using Continuous Integration Deploy cluster hosts on cloud services and automate your infrastructure In Detail Docker orchestration is what you need when transitioning from deploying containers individually on a single host to deploying complex multi-container apps on many machines. This book covers the new orchestration features of Docker 1.12 and helps you efficiently build, test, and deploy your application using Docker. You will be shown how to build multi-container applications using Docker Compose. You will also be introduced to the building blocks for multi-host Docker clusters such as registry, overlay networks, and shared storage using practical examples. This book gives an overview of core tools such as Docker Machine, Swarm, and Compose which will enhance your orchestration skills. You’ll learn how to set up a swarm using the decentralized building block. Next, you’ll be shown how to make the most out of the in-built orchestration feature of Docker engine and you’ll use third-party tools such as Kubernetes, Mesosphere, and CoreOS to orchestrate your existing process. Finally, you will learn to deploy cluster hosts on cloud services and automate your infrastructure. Style and approach This comprehensive guide will take you through the orchestration feature of Docker. Using practical examples, you will discover various tools that can be used to manage multiple containers with ease.
目录展开

Docker Orchestration

Docker Orchestration

Credits

About the Author

About the Reviewer

www.PacktPub.com

Why subscribe?

Customer Feedback

Preface

What this book covers

What you need for this book

Who this book is for

Conventions

Reader feedback

Customer support

Downloading the example code

Downloading the color images of this book

Errata

Piracy

Questions

1. Getting Started with Docker Orchestration

Installing Docker Engine

Installing with Docker Machine

Starting a host on AWS

Starting a host on GCE

Starting a host on Microsoft Azure

Installing on a running Linux host

Introducing Docker-specific distributions

CoreOS

RancherOS

Project Atomic / RHEL Atomic

Running single container applications

What is running?

Inspecting your container

Summary

2. Building Multi-Container Applications with Docker Compose

Building an image with Docker Engine

Building from a Dockerfile

Tagging the image

Skipping the build cache

Running the image

Installing Docker Compose

Writing a Docker Compose file

Multi-container applications

Using environment files

Extending compose files

Controlling start order

Using Docker networks

Keeping your data safe in volumes

Summary

3. Cluster Building Blocks – Registry, Overlay Networks, and Shared Storage

Creating a Docker Registry

Using the Docker Hub

Logging in

Working with a repository

Automating image builds with Docker Hub

Integration with Docker Cloud

Using the GitLab Container Registry

Installing GitLab on Ubuntu

Enabling Docker Registry on a project

Introducing the Docker Trusted Registry and Docker Datacenter

Building it yourself

Connecting containers with overlay networks

Using Docker native overlays

Working with DNS-SD

Publishing services with mesh routing mode

Using Weave

Installing Weave

Connecting containers to Weave

Using Flannel

Configuring etcd and Flannel

Starting a CoreOS cluster with Flannel

Connecting to Flannel

Using shared network storage for Docker volumes

Introducing Ceph

Using Ceph with Docker

Creating a Docker volume

Other shared storage plugins

Summary

4. Orchestration with Docker Swarm

Setting up a swarm

Initializing a swarm

Managing a swarm

Adding a node

Promoting and demoting nodes

Changing node availability

Pausing a node

Draining a node

Activating a node

Removing nodes

Recovering from a disaster

Restarting the full cluster

Backup and recovery

Backing up the swarm

Recovering a swarm

Backing up services

Grouping nodes with labels

Managing services

Running services

Creating replicas

Running global services

Setting constraints

Stopping services

Upgrading a service with rolling updates

Using Docker Compose with swarm

Building images

Starting an application

Bundling an application

Deploying a stack

Introducing Docker Datacenter

Summary

5. Deploying and Managing Services with Kubernetes

Getting to know Kubernetes

Command-line tools

Master components

Node components

Installing Kubernetes

Installing with kubeadm

Installing with kube-up.sh

Installing add-ons

Managing resources

Creating resources

Deleting resources

Running pods

Defining a pod

Viewing pods

Environment

Multi-container pods

Using secrets

Creating secrets

Using secrets in environment variables

Using secrets in files

Logging into a container

Deleting a pod

Using deployments

Creating a single container deployment

Creating a multi-container deployment

Scaling a deployment

Rolling updates

Updating a deployment

Getting the rollout history

Rolling back an update

Deleting a deployment

Running pods on every node with DaemonSets

Introducing scheduled jobs

Using labels

Using selectors to find resources

Using namespaces

Viewing namespaces

Creating namespaces

Switching namespaces

Deleting a namespace

Networking

Services

Creating a service

Listing services

Introducing DNS-SD

Using volumes

Using plain volumes

Storing long-lived data in persistent volumes

Creating a PersistentVolume

Creating the PersistentVolumeClaim resource

Using a PersistentVolumeClaim as a volume

Further reading

Summary

6. Working with Mesosphere

Getting started with DC/OS

Logging into the web interface

Installing the DC/OS client

Managing applications

Running a simple application

Stopping an application

Removing an application

Forcing Marathon to pull images

Using environment variables

Scaling applications

Checking application health

Using TCP and HTTP checks

Using command checks

Deploying rolling updates

Setting an upgrade strategy

Testing updates with blue-green deployments

Introducing pods

Using network services and load balancing

Discovering services with DNS

Connecting to the overlay network

Using virtual IPs

Using the Marathon load balancer

Providing persistent storage

Using local volumes

Using external volumes

Using a private registry

Summary

7. Using Simpler Orchestration Tools – Fleet and Cattle

Using Fleet

Starting Fleet

Verifying the cluster

Starting a container

Monitoring services

Viewing service logs

Stopping a service

Using environment variables

Scheduling services with affinity

Setting positive affinity

Using negative affinity

High availability

Sidekick services

Starting global units

Using Rancher Cattle

Installing Rancher

Installing Rancher server

Installing Rancher agents

Installing Rancher Compose

Introducing environments

Managing services

Starting a stack

Stopping a stack

Removing a stack

Upgrading a stack

Rolling back and confirming upgrades

Checking service health

Scheduling and affinity

Using networking services

Discovering services

Load balancer

Further reading

Summary

8. Monitoring Your Cluster

Logging with containers

Using Docker logging plugins

Logging containers that do not play by the rules

Logging with the ELK stack

Starting Elasticsearch

Starting Logstash

Viewing the logs with Kibana

Remote logging in Docker Datacenter

Logging from Kubernetes

Logging from Mesosphere

Logging your Docker hosts

Collecting and graphing performance data

Collecting data with collectd

Running collectd

Configuring collectd

Storing performance data in Elasticsearch

Storing performance data in InfluxDB

Graphing data with Kibana

Creating a new chart

Adding charts to a dashboard

Graphing data with Grafana

Installing Grafana

Adding data source

Creating a new dashboard

Creating a graph

Using Heapster in Kubernetes

Considerations for monitoring system health

Monitor services

Watching services in real time with Sysdig

Summary

9. Using Continuous Integration to Build, Test, and Deploy Containers

The importance of using CI

Using GitLab for CI

Setting up GitLab for CI

Installing the GitLab Runner on Ubuntu

Registering a runner

Enabling a Docker Repository

Adding the project to the repository

Creating .gitlab-ci.yml

Testing the image

Cleanup jobs

Releasing the image

Deploying the image

Deploying the image manually

Deploying to Kubernetes

Building DAB files

Using Docker Cloud for CI

Enabling autobuilds

Testing the image

Summary

10. Why Stop at Containers? Automating Your Infrastructure

Configuring Docker hosts

Using configuration management

Configuring a server on boot

Using a custom image

Building a new image with Packer

Preparing the Ubuntu Cloud Image

Building the image

Using Puppet with Packer

Treating infrastructure like code

Post-build configuration

Automating host deployment

Deploying hosts with Terraform

Creating a Terraform configuration

Running Terraform

Showing the cluster state

Deploying hosts with Docker Cloud

Introducing Docker for AWS and Docker for Azure

Scaling down nodes

Summary

累计评论(0条) 0个书友正在讨论这本书 发表评论

发表评论

发表评论,分享你的想法吧!

买过这本书的人还买过

读了这本书的人还在读

回顶部