Chapter 10. Maintaining Docker Containers

In this chapter, we will cover the following recipes:

  • Testing Docker containers with BATS
  • Test-Driven Development (TDD) with Docker and ServerSpec
  • The workflow for creating automated Docker builds from Git
  • The workflow for connecting the Continuous Integration (CI) system
  • Scanning for vulnerabilities with Quay.io and Docker Cloud
  • Sending Docker logs to AWS CloudWatch Logs
  • Monitoring and getting information out of Docker
  • Debugging containers using sysdig

Introduction

In this chapter, we'll explore some advanced and highly interesting areas that probably most developers today are already used to. Infrastructure code is still code, so it should be no different than software code; the same principle should apply. This means that the Docker code should be testable, the builds automatic, and the CI systems connected to our Git servers so they could continuously apply the tests. In addition to this, security checks should be part of the mandatory release process and the logs easy to access, even if the application is scaled on multiple machines. Also note that containers shouldn't be black boxes, and highly performant debugging tools should be available for us to do our work. The good news is that these topics will be covered in this chapter, because all of this can be done easily.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.191.205.99