Difficulty: Beginner
Estimated Time: 20-25 minutes

In this scenario, you will quickly add a static analysis tool to the delivery system.

Manually installing and configuring tools is slow and error-prone. It's also risky to do it directly on the live delivery system that application teams depend on.

Instead, we want to configure and add this tool via code. This can be as simple as specifying the container image to use and setting up credentials and ports.

At the same time, by keeping everything configured as code, we guarantee that we can at any moment recreate a fully running delivery system - including any tools added along the way.

We will add SonarQube to our delivery chain that already included Jenkins and Artifactory.

Now let's get started!

Manuel Pais

In a very short sequence of steps, we have updated our configuration and launched a new version of the delivery system with SonarQube up and running.

All the necessary configuration was coded, allowing a full restore of the system at any time.

04 Minimize Time To Repair Pipeline Tooling Issues

Step 1 of 3

Add aggregated logging

Aggregated logging for CI/CD means that we ship all the logs from all the tools (Jenkins, Artifactory, etc) off the containers where they are generated, to a central location for easy querying and diagnosing across the entire toolchain.

In this scenario we will use the Elastic stack for aggregated logging:

In order to add to our delivery toolchain, we can use the official Elastic stack docker images.

Your environment already includes an updated docker-compose.yml file which sets up the Elastic stack. This is because we are using docker-compose as a basic container orchestration tool for our toolchain. The same approach would be applicable for other orchestrators like Kubernetes.

You can see the changes made to docker-compose.yml to run the Elastic stack by executing this command:

diff docker-compose-before.yml docker-compose.yml