Install and enable Keptn
Keptn must be installed, enabled, and integrated into each cluster you want to monitor. This is because Keptn communicates with the Kubernetes scheduler for tasks such as enforcing checks natively, stopping a deployment from proceeding when criteria are not met, doing post-deployment evaluations and tracing all activities of all deployment workloads on the cluster.
Two methods are supported for installing Keptn:
Releases v0.7.0 and later can be installed using the Helm Chart. This is the preferred strategy because it allows you to customize your cluster.
See the use manifests section for more information on installing via manifest. This is the less-preferred way because it does not support customization.
After Keptn is installed, you must Enable Keptn for your cluster in order to run some Keptn functionality.
You are then ready to Integrate Keptn with your applications.
Use Helm Chart
Version v0.7.0 and later of Keptn should be installed using Helm Charts. The command sequence to fetch and install the latest release is:
helm repo add klt https://charts.lifecycle.keptn.sh helm repo update helm upgrade --install keptn klt/klt \ -n keptn-lifecycle-toolkit-system --create-namespace --wait
Note that the
helm repo update command is used for fresh installs
as well as for upgrades.
Some helpful hints:
--version <version>flag on the
helm upgrade --installcommand line to specify a different Keptn version.
Use the following command sequence to see a list of available versions:
helm repo update helm search repo klt
To verify that the Keptn components are installed in your cluster, run the following command:
kubectl get pods -n keptn-lifecycle-toolkit-system
The output shows all components that are running on your system.
Modify Helm configuration options
Helm chart values can be modified before the installation.
This is useful if you want to install only the
rather than the full Toolkit
or if you need to change the size of the installation.
To modify configuration options, download a copy of the helm/chart/values.yaml file, modify some values, and use the modified file to install Keptn:
helm get values RELEASE_NAME [flags] > values.yaml
Edit your local copy to modify some values
Install Keptn by adding the following string to your
helm upgradecommand line:
You can also use the
to specify a value change for the
helm upgrade --install command.
Configuration options are specified using the format:
For more information,see
Versions v0.10.0 and earlier of Keptn can be installed using manifests, although we recommend that you use Helm Charts because they allow you to easily customize your configuration.
Versions 0.6.0 and earlier can only be installed using manifests.
Note When installing Version 0.6.0, you must first install the
cert-managerwith the following command sequence:
kubectl apply \ -f https://github.com/cert-manager/cert-manager/releases/download/v1.11.0/cert-manager.yaml kubectl wait \ --for=condition=Available deployment/cert-manager-webhook -n cert-manager --timeout=60s
Use a command sequence like the following to install Keptn from the manifest, specifying the version you want to install.
kubectl apply \ -f https://github.com/keptn/lifecycle-toolkit/releases/download/v0.6.0/manifest.yaml kubectl wait --for=condition=Available deployment/lifecycle-operator \ -n keptn-lifecycle-toolkit-system --timeout=120s
Keptn and its dependencies are now installed and ready to use.
Enable Keptn for your cluster
apiVersion: v1 kind: Namespace metadata: name: simplenode-dev annotations: keptn.sh/lifecycle-toolkit: "enabled"
You see the annotation line
This annotation tells the webhook to handle the namespace.
After enabling Keptn for your namespace(s), you are ready to Integrate Keptn with your applications.