Continuous Delivery with Docker and Jenkins
Create secure applications by building complete CI/CD pipelines, 2nd Edition
Rafał Leszko
- 350 pagine
- English
- ePUB (disponibile sull'app)
- Disponibile su iOS e Android
Continuous Delivery with Docker and Jenkins
Create secure applications by building complete CI/CD pipelines, 2nd Edition
Rafał Leszko
Informazioni sul libro
Create a complete Continuous Delivery process using modern DevOps tools such as Docker, Kubernetes, Jenkins, Docker Hub, Ansible, GitHub and many more.
Key Features
- Build reliable and secure applications using Docker containers.
- Create a highly available environment to scale a Docker servers using Kubernetes
- Implement advance continuous delivery process by parallelizing the pipeline tasks
Book Description
Continuous Delivery with Docker and Jenkins, Second Edition will explain the advantages of combining Jenkins and Docker to improve the continuous integration and delivery process of an app development. It will start with setting up a Docker server and configuring Jenkins on it. It will then provide steps to build applications on Docker files and integrate them with Jenkins using continuous delivery processes such as continuous integration, automated acceptance testing, and configuration management.
Moving on, you will learn how to ensure quick application deployment with Docker containers along with scaling Jenkins using Kubernetes. Next, you will get to know how to deploy applications using Docker images and testing them with Jenkins. Towards the end, the book will touch base with missing parts of the CD pipeline, which are the environments and infrastructure, application versioning, and nonfunctional testing.
By the end of the book, you will be enhancing the DevOps workflow by integrating the functionalities of Docker and Jenkins.
What you will learn
- Get to grips with docker fundamentals and how to dockerize an application for the CD process
- Learn how to use Jenkins on the Cloud environments
- Scale a pool of Docker servers using Kubernetes
- Create multi-container applications using Docker Compose
- Write acceptance tests using Cucumber and run them in the Docker ecosystem using Jenkins
- Publish a built Docker image to a Docker Registry and deploy cycles of Jenkins pipelines using community best practices
Who this book is for
The book targets DevOps engineers, system administrators, docker professionals or any stakeholders who would like to explore the power of working with Docker and Jenkins together. No prior knowledge of DevOps is required for this book.
Domande frequenti
Informazioni
Section 1: Setting Up the Environment
- Chapter 1, Introducing Continuous Delivery
- Chapter 2, Introducing Docker
- Chapter 3, Configuring Jenkins
Introducing Continuous Delivery
- Understanding CD
- The automated deployment pipeline
- Prerequisites to CD
- Building the CD process
- Creating a complete CD system
Understanding CD
The traditional delivery process
Introducing the traditional delivery process
- Development: The developers (sometimes together with business analysts) work on the product. They often use Agile techniques (Scrum or Kanban) to increase the development velocity and to improve communication with the client. Demo sessions are organized to obtain a customer's quick feedback. All good development techniques (such as test-driven development or extreme programming practices) are welcome. Once implementation is complete, the code is passed to the QA team.
- Quality Assurance: This phase is usually called User Acceptance Testing (UAT) and it requires a code freeze on the trunk code base, so that no new development would break the tests. The QA team performs a suite of Integration Testing, Acceptance Testing, and Non-functional analysis (performance, recovery, security, and so on). Any bug that is detected goes back to the development team, so developers usually have their hands full. After the UAT phase is completed, the QA team approves the features that are planned for the next release.
- Operations: The final phase, usually the shortest one, means passing the code to the operations team, so that they can perform the release and monitor production. If anything goes wrong, they contact developers to help with the production system.
Shortcomings of the traditional delivery process
- Slow delivery: The customer receives the product long after the requirements were specified. This results in unsatisfactory time to market and delays customer feedback.
- Long feedback cycle: The feedback cycle is not only related to customers, but also to developers. Imagine that you accidentally created a bug and you learn about it during the UAT phase. How long does it take to fix something you worked on two months ago? Even dealing with minor bugs can take weeks.
- Lack of automation: Rare releases don't encourage automation, which leads to unpredictable releases.
- Risky hotfixes: Hotfixes can't usually wait for the full UAT phase, so they tend to be tested differently (the UAT phase is shortened) or not tested at all.
- Stress: Unpredictable releases are stressful for the operations team. What's more, the release cycle is usually tightly scheduled, which imposes an additional stress on developers and testers.
- Poor communication: Work passed from one team to another represents the waterfall approach, in which people start to care only about their part, rather than the complete product. In case anything goes wrong, that usually leads to the blame game instead of cooperation.
- Shared responsibility: No team takes responsibility for the product from A to Z:
- For developers: done means that requirements are implemented
- For testers: done means that the code is tested
- For operations: done means that the code is released
- Lower job satisfaction: Each phase is interesting for a different team, but other teams need to support the process. For example, the development phase is interesting for developers but, during the other two phases, they still need to fix bugs and support the release, which usually is not interesting for them at all.
Benefits of CD
- Fast delivery: Time to market is significantly reduced as customers can use the product as soon as development is completed. Remember that the software delivers no revenue until it is in the hands of its users.
- Fast feedback cycle: Imagine you created a bug in the code, which goes into production the same day. How much time does it take to fix something you worked on the same day? Probably not much. This, together with the quick rollback strategy, is the best way to keep...