Pipeline configuration
Solution Designer provides a UI to configure the pipelines used to deploy the built projects to the desired target project. This configuration can be accessed from the CI/CD capability which is located on the navigation bar on the left. On this page it is possible to create, edit and delete the pipeline configurations.
Create pipeline configurations
To create a new pipeline configuration for a project to deploy it to a particular namespace (k5-project) use the "Create" capability on the project's "Pipeline configuration" tab. The master data you need to provide is the following:
Property | Description |
---|---|
Type | There are 2 types of pipelines: release and deploy . A release pipeline publishes the project to the component repository while a deploy pipeline deploys the project to the selected OpenShift project. |
Name | A unique name for your pipeline configuration |
Enable unit test execution | If turned on, all available unit tests will be executed automatically. |
Auto trigger | A pipeline run will be triggered automatically whenever the source repository (Git) was changed. |
Timestamp tag | Adds a timestamp to pre-release versions to ensure that every commit gets built without manually changing the version (only available for release pipelines) |
Enable unique SemVer check | Will check if the current version has already been published or not to prevent previous versions to be overwritten unintentionally (only available for release pipelines) |
Source repository (Git) information | You can either use personal Git credentials or dedicated Git credentials. Choosing the latter, you will be asked to fill in the Git username and Git access token. The Git username is the name of a Git user with access to the Git repository of the project. This user will be used to access the Git repository when running the pipeline. The Git access token is the token of a Git user with access to the Git repository of the project. This token will be used to access to the Git repository when running the pipeline. |
Deploy target information | This is only for the deploy pipeline. The OpenShift target project to which the project will be deployed |
Prerequisites for the "auto trigger" feature
It is mandatory that a webhook (for push events) is activated in the regarding Git repository. This has to be done manually. Regardless of the Git provider, for creating a webhook (trigger), a webhook URL and secret token is needed.
The webhook URL can be found in the OpenShift route
k5-pipeline-triggerwebhook
in the namespace of the Solution Hub.default:
k5-pipeline-triggerwebhook-<zen>.<cluster-domain>
The token secret can be found in the OpenShift secret
k5-git-webhook-secret
in the namespace of the Solution Hub
The following commands can be used to get the webhook URL and the token:
oc -n zen get route k5-pipeline-triggerwebhook -o jsonpath='{.spec.host}'; echo
oc -n zen get secret k5-git-webhook-secret -o jsonpath='{.data.token}' | base64 -d; echo
Edit pipeline configuration
To edit a pipeline configuration either click the "Edit" capability on a pipeline row or on the "Features" section after opening the Pipeline Details view. The following fields can be edited:
Property | Description |
---|---|
Enable unit test execution | If turned on, all available unit tests will be executed automatically. |
Auto trigger | A pipeline run will be triggered automatically whenever the source repository (Git) was changed. |
Timestamp tag | Adds a timestamp to pre-release versions to ensure that every commit gets built without manually changing the version (only available for release pipelines) |
Enable unique SemVer check | Will check if the current version has already been published or not to prevent previous versions to be overwritten unintentionally (only available for release pipelines) |
Deploy target information | This is only for the deploy pipeline. The OpenShift target project to which the project will be deployed |
Edit pipeline configuration source repository information
Since the pipeline configuration uses dedicated git credentials (If you choose to use your personal git credentials, those will be resolved at creation.) you might find the need to update the credentials after your access token changes. To do this open the "Info" view of the pipeline configuration and click on the "Edit" button in the "Source Repository (Git) Information" section. The following fields can be edited:
Property | Description |
---|---|
Git Access Token | The Git access token is the token of a Git user with access to the Git repository of the project. This token will be used to access to the Git repository when running the pipeline. |
Manage pipeline configurations
Solution Designer offers several tools to manage all your pipeline configurations from within the CI/CD capability that can be found on the navigation bar on the left. The CI/CD page is separated in the following tabs:
Pipeline configurations
Pipeline runs
Pipeline configurations tab
The pipeline configurations tab shows a list of all pipelines configured for this service project. The table also provides information on the pipeline (incl. a link to the OpenShift Web Console), the pipeline type (release or deploy), the linked name of the project, the linked name of the last pipeline run, as well as the last run status and the last run time.
Each row consists of one pipeline configuration and provides the following inline capabilities:
Info button: opens the "Details" view of that configuration
Edit button: opens an action to edit the feature flags of the pipeline configuration
Run button: triggers the pipeline
Delete button: deletes the pipeline configuration
Pipeline runs tab
The pipeline runs tab shows a list of all pipeline runs related with this service project. It provides the following information:
Name of the pipeline run (with link to OpenShift Web Console)
Name of the project (with link to OpenShift Web Console)
Time started
Run status
Task status
Duration
Name of the pipeline (with link to OpenShift Web Console) - this column is not visible by default