4 Welcome to Docker

 

This chapter covers:

  • Understanding the importance of containers and how it fits into the microservices architecture.
  • Understand the differences between a virtual machine and a container
  • Understand docker and his main components
  • Integrate docker with a microservice

To successfully continue building our microservices, we need to address the portability issue of how we are going to execute our microservices in different technology locations. Remember, portability is the ability to use or move a software to different environments. In recent years the concept of containers has gained more and more strength within the world of technology and software development, passing from a "nice to have" into a must-have in the software architectures. Although this technology has been on the market for a few years now, not everybody is familiarized with containers that is why in this chapter, I will give you a brief introduction to containers using Docker, a technology that I selected because it is deployable to all the major cloud providers.

The use of containers is an agile and useful way to migrate and execute any software development from one platform to another, for example, from the developer's machine to a physical or virtual enterprise server. With containers we can replace the traditional models of web servers with smaller and much more adaptable virtualized software containers offering advantages such as speed, portability and scalability to our microservices.

4.1   Containers or virtual machines?

 

4.2   What is Docker?

 
 

4.3   Dockerfiles

 
 

4.3.1   Dockerfile commands

 
 

4.4   Docker compose

 
 
 

4.4.1   Docker-compose commands

 
 
 

4.5   Integrating docker with our microservices

 
 
 

4.5.1   Building the Docker Image

 
 
 

4.5.2   Launching the services with Docker Compose

 
 

4.6   Summary

 
 
 
sitemap

Unable to load book!

The book could not be loaded.

(try again in a couple of minutes)

manning.com homepage
test yourself with a liveTest