Install
TOC
Installing Alauda DevOps Pipelines
This guide provides cluster administrators with the process to install the Alauda DevOps Pipelines Operator on a Kubernetes cluster.
Prerequisites:
- You have access to the Kubernetes cluster with an account that has
cluster-adminprivileges. - You have installed the
kubectlCLI. - Your cluster has the Marketplace feature enabled or the Operator Hub is accessible.
Installing Alauda DevOps Pipelines Using the Web Console
You can install the Alauda DevOps Pipelines Operator by using the Operators listed in the Marketplace or OperatorHub. When you install the Alauda DevOps Pipelines Operator, the required Custom Resources (CRs) are automatically installed alongside the Operator.
The Operator provides the following Custom Resource Definitions (CRDs) to manage the Tekton components: tektonconfigs.operator.tekton.dev, tektonpipelines.operator.tekton.dev, tektontriggers.operator.tekton.dev, tektonhubs.operator.tekton.dev, and more.
If Tekton Pipelines is already installed on your cluster, the existing installation will be seamlessly upgraded by the Operator.
The Alauda DevOps Pipelines Operator provides the option to select which components to install by specifying a preset configuration in the TektonConfig Custom Resource (CR). The TektonConfig CR is automatically installed when the Operator is installed. Supported presets include:
- Lite: Installs only Tekton Pipelines.
- Basic: Installs Tekton Pipelines and Tekton Triggers.
- All: This is the default preset used when installing the
TektonConfigCR. This preset installs all Tekton components, including Tekton Pipelines, Tekton Triggers.
Steps
-
In the Web console, navigate to Marketplace or OperatorHub.
-
Use the Filter by keyword box to search for
Alauda DevOps PipelinesOperator in the directory. Click on theAlauda DevOps PipelinesOperator title. -
Read the Operator overview on the
Alauda DevOps PipelinesOperator page. Click Install. -
On the Install Operator page:
- For Installation Mode, choose All namespaces on the cluster (default). This mode installs the Operator in the default
tekton-operatornamespace, allowing the Operator to monitor and be available in all namespaces in the cluster. - For Approval Strategy, select Automatic. This ensures that future upgrades of the Operator are handled automatically by the Operator Lifecycle Manager (OLM). If you choose the
Manualapproval strategy, OLM will create update requests. As the cluster administrator, you must manually approve the OLM update requests to upgrade the Operator to a new version. - Choose an Update Channel if multiple channels are available.
- For Installation Mode, choose All namespaces on the cluster (default). This mode installs the Operator in the default
-
Click Install. You will see the Operator on the Installed Operators page.
-
Verify that the Status is set to Succeeded to confirm the successful installation of the
Alauda DevOps PipelinesOperator. -
Verify that all components of the
Alauda DevOps PipelinesOperator have been successfully installed. Log in to the cluster in a terminal and run the following command:Example Output
If the
READYcondition isTrue, it indicates that the Operator and its components have been successfully installed.Additionally, check the versions of the components by running the following command:
Example Output
Installing Alauda DevOps Pipelines Using CLI
You can install the Alauda DevOps Pipelines Operator from the OperatorHub using the Command Line Interface (CLI).
Steps
- Create a
Subscriptionobject YAML file to subscribe a namespace to theAlauda DevOps PipelinesOperator, for example,sub.yaml:
Example Subscription YAML
- The channel name you want to subscribe to. The
latestchannel allows for the installation of the latest stable version of theAlauda DevOps PipelinesOperator. - The name of the Operator to subscribe to.
- The name of the
CatalogSourceobject providing the Operator. - The namespace of the
CatalogSourceobject. This may vary depending on your cluster configuration.
-
Create the
Subscriptionobject by running the following command:The subscription will install the
Alauda DevOps PipelinesOperator in thetekton-operatornamespace. The Operator will automatically install Tekton components in the default target namespacetekton-pipelines.
Uninstalling Alauda DevOps Pipelines
Cluster administrators can uninstall the Alauda DevOps Pipelines Operator by performing the following steps:
- Delete any optional component CRs if they exist, and then delete the
TektonConfigCR. - Uninstall the
Alauda DevOps PipelinesOperator. - Delete the Custom Resource Definitions (CRDs) for the
operator.tekton.devgroup if needed.
Simply uninstalling the Operator will not remove the Alauda DevOps Pipelines components created by default during the installation of the Operator.
Deleting Alauda DevOps Pipelines Resource Instances
First, delete the TektonConfig CR and any other Tekton component CRs if they exist.
Steps
- In the Web console, navigate to Administration → CustomResourceDefinitions or equivalent section.
- Search for the
TektonConfigCRD. - Click on the
TektonConfigCRD to display the detailed page. - Click the Instances tab.
- If an instance is displayed, click the
Optionsmenu of the displayed instance. - Select Delete.
- Click Delete to confirm the deletion of the CR.
- Deleting the
TektonConfigresource will cascade delete the automatically createdTektonPipelines,TektonTriggers,TektonHubs,TektonChains, etc. components.
- Deleting the
- Repeat these steps for any other Tekton component CRs that may exist.
- If you manually created
TektonResultsorOpenShiftPipelinesAsCodes, you may need to manually delete it.
- If you manually created
Uninstalling the Alauda DevOps Pipelines Operator
You can uninstall the Alauda DevOps Pipelines Operator using the Web console.
Steps
- From the Marketplace or OperatorHub page, navigate to Installed Operators.
- Find the
Alauda DevOps PipelinesOperator in the list. - Click the Options menu and select Uninstall Operator.
- In the Uninstall Operator? window, select Delete all operand instances for this operator, then click Uninstall.
Deleting Alauda DevOps Pipelines Resource Definitions (Optional)
If you want to completely remove all traces of the Tekton Operator, you can delete the Custom Resource Definitions (CRDs) for the operator.tekton.dev group.
Steps
- In the Web console, navigate to Administration → CustomResourceDefinitions or equivalent section.
- Search for CRDs with the keyword
operator.tekton.dev. - For each CRD you want to delete:
- Click the Options menu.
- Select Delete CustomResourceDefinition.
- Click Delete to confirm the deletion of the CRD.
Customizing Configuration in TektonConfig
In Alauda DevOps Pipelines, you can customize the following configurations using the TektonConfig Custom Resource (CR):
- Optimize Tekton Pipelines performance, including high availability mode for the Tekton Pipelines controller
- Configure the Tekton Pipelines control plane
- Change the default service account
- Configure pipeline resolvers
- Disable specific features or components
Prerequisites
The Alauda DevOps Pipelines Operator must be installed.
Tuning Performance with TektonConfig CR
You can modify the fields under the .spec.pipeline.performance parameter in the TektonConfig Custom Resource (CR) to change the high availability (HA) support and performance configuration of the Tekton Pipelines controller.
Example of TektonConfig Performance Fields
All fields are optional. When set, the Alauda DevOps Pipelines Operator includes most fields as parameters in the tekton-pipelines-controller deployment under the tekton-pipelines-controller container. The Operator also updates the bucket field in the config-leader-election ConfigMap under the tekton-pipelines namespace.
If no values are specified, the Operator does not update these fields and applies the default values of the Tekton Pipelines controller.
If you modify or remove any performance fields, the Operator will update the tekton-pipelines-controller deployment and the config-leader-election ConfigMap (if the bucket field has changed) and recreate the tekton-pipelines-controller pod.
High availability (HA) mode is applicable to the Tekton Pipelines controller; it creates and launches pods based on pipeline runs and task runs definitions. Without HA mode, a single pod performs these operations, which may lead to high loads and significant delays.
In HA mode, Tekton Pipelines uses several pods (replicas) to perform these operations. Initially, Tekton Pipelines distributes each controller operation among the buckets. Each replica selects operations from one or more buckets. If two replicas can select the same operation simultaneously, the controller internally decides who will execute that operation.
HA mode does not affect tasks that run after the pod is created.
Configuring Tekton Pipelines Control Plane
You can customize the Tekton Pipelines control plane by editing the configuration fields in the TektonConfig Custom Resource (CR). The Alauda DevOps Pipelines Operator automatically includes default values for the configuration fields so you can use the Tekton Pipelines control plane.
Process
- In the Web console, navigate to the CustomResourceDefinitions section.
- Search for the
tektonconfigs.operator.tekton.devCustom Resource Definition (CRD). - Click on TektonConfig to view the CRD detail page.
- Click on the Instances tab.
- Click on the config instance to view the details of the
TektonConfigCR. - Click on the YAML tab.
- Edit the
TektonConfigYAML file according to your requirements.
Example of TektonConfig CR with Default Values
Feature Flag Options
The following feature flags can be configured in the TektonConfig CR to control different behaviors of Tekton Pipelines:
disable-affinity-assistant(Default:false)disable-creds-init(Default:false)enable-api-fields(Default:stable)enable-custom-tasks(Default:true)await-sidecar-readiness(Default:true)running-in-environment-with-injected-sidecars(Default:true)require-git-ssh-secret-known-hosts(Default:false)enable-provenance-in-status(Default:true)
For detailed descriptions of each option, please refer to the Tekton Operator documentation.
Changing the Default Service Account
You can change the default service account for Tekton Pipelines by editing the default-service-account field in the .spec.pipeline specification. The default service account name is pipeline.
Example
Setting Labels and Annotations for the Installation Namespace
You can set labels and annotations for the tekton-pipelines namespace where the Operator installs Tekton Pipelines components.
Specify labels and annotations by adding them in the .spec.targetNamespaceMetadata specification of the TektonConfig Custom Resource (CR).
Example of Setting Labels and Annotations for the tekton-pipelines Namespace
Next Steps
After successfully installing the Alauda DevOps Pipelines Operator: