This chapter introduced you to how to build images and run containers with your own microservices using Docker. We packed all of the microservices we created in Chapter 9, Simple REST Definition and Request Routing with Frameworks, and Chapter 11, Involving Concurrency with Actors and the Actix Crate, and learned how to build images manually and start a container. We also added the dbsync worker, which applied all necessary migrations and prepared a database for use with the users and content microservices.
Also, we considered approaches to hiding the source code of a microservice and used the cache of a container to copy a compiled binary to an empty image without building artifacts.
In the second half of the chapter, we learned how to run multiple microservices with necessary dependencies (such as databases and mail servers) at once. We used the Docker Compose...