Ambassadors Docker Fundamentals a2622f1 246 2015 Docker Inc Ambassadors Weve

Ambassadors docker fundamentals a2622f1 246 2015

This preview shows page 246 - 255 out of 350 pages.

Ambassadors Docker Fundamentals a2622f1 246 © 2015 Docker Inc
Image of page 246
Ambassadors We've already seen a couple of ways we can manage our application architecture in Docker. With links. Using host-based volumes. Using data volumes shared between containers. We're now going to see a pattern for service portability we call: ambassadors. Ambassadors Docker Fundamentals a2622f1 247 © 2015 Docker Inc
Image of page 247
Introduction to Ambassadors The ambassador pattern: Takes advantage of Docker's lightweight linkages and abstracts connections between services. Allows you to manage services without hard-coding connection information inside applications. To do this, instead of directly connecting containers you insert ambassador containers. Ambassadors Docker Fundamentals a2622f1 248 © 2015 Docker Inc
Image of page 248
Ambassadors Docker Fundamentals a2622f1 249 © 2015 Docker Inc
Image of page 249
Interacting with ambassadors The web application container uses a normal link to connect to the ambassador. The database container is linked with an ambassador as well. For both containers, there is no difference between normal operation and operation with ambassador containers. If the database container is moved, its new location will be tracked by the ambassador containers, and the web application container will still be able to connect, without reconfiguration. Ambassadors Docker Fundamentals a2622f1 250 © 2015 Docker Inc
Image of page 250
Implementing the ambassador pattern Different deployments will use different underlying technologies. On-premise deployments with a trusted network can track container locations in e.g. Zookeeper, and generate HAproxy configurations each time a location key changes. Public cloud deployments or deployments across unsafe networks can add TLS encryption. Ad-hoc deployments can use a master-less discovery protocol like avahi to register and discover services. It is also possible to do one-shot reconfiguration of the ambassadors. It is slightly less dynamic but has much less requirements. Ambassadors Docker Fundamentals a2622f1 251 © 2015 Docker Inc
Image of page 251
Section summary We've learned how to: Understand the ambassador pattern and what it is used for (service portability). For more information about the ambassador pattern, including demos on Swarm and ECS: look for DVO317 (AWS re:invent talk). Ambassadors Docker Fundamentals a2622f1 252 © 2015 Docker Inc
Image of page 252
Compose For Development Stacks Compose For Development Stacks Docker Fundamentals a2622f1 253 © 2015 Docker Inc
Image of page 253
Lesson 19: Using Docker Compose for Development Stacks Objectives Dockerfiles are great to build a single container. But when you want to start a complex stack made of multiple containers, you need a different tool. This tool is Docker Compose. In this lesson, you will use Compose to bootstrap a development environment.
Image of page 254
Image of page 255

You've reached the end of your free preview.

Want to read all 350 pages?

  • Fall '19

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture