Extending Build Pack Pipelines
This lesson explains how we can extend the build pack pipelines to run tests.
We'll cover the following
- Creating a new branch
- Increasing the value of replicaCount in values.yaml
- Removing http:// from the tests
- Running unit tests
- Inspecting the jenkins-x.yml file
- Pushing the changes to GitHub
- Inspecting the build logs
- Creating a target in Makefile for functional tests
- Modifying jenkins-x.yml to add the dynamic address of the current PR
- Pushing the changes to GitHub
- Retrieving logs for functional tests
- What happens if the run fails?
- Removing the failing test
We already saw that pipelines based on the new format have a single line: buildPack: go
. To be more precise, those that are created based on a build pack are like that. While you can certainly create a pipeline from scratch, most use cases benefit from having a good base inherited from a build pack. For some, the base will be everything they need, but for others, it will not. There is a high probability that you will need to extend those pipelines by adding your own steps or even replacing a whole lifecycle (e.g., promote
). Our next mission is to figure out how to accomplish that. We’ll explore how to extend pipelines used with serverless Jenkins X.
Creating a new branch
As any good developer would (excluding those who work directly with the master branch), we’ll start by creating a new branch.
Get hands-on with 1400+ tech skills courses.