1111
- You have access to the cluster as a user with the cluster-admin role.
- You have installed the kubectl
- You have Ingress running on you cluster if not follow
- Install and verify nginx.
kubectl apply -f https://raw.githubusercontent.com/kubernetes/ingress-nginx/controller-v0.45.0/deploy/static/provider/cloud/deploy.yaml
kubectl get pods -n ingress-nginx \
-l app.kubernetes.io/name=ingress-nginx --watch
kubectl apply -f https://storage.googleapis.com/tekton-releases/operator/previous/v0.54.0/release.notags.yaml
Check the status of Operator:
1. kubectl get deploy -n tekton-operator
NAME READY UP-TO-DATE AVAILABLE AGE
tekton-operator 1/1 1 1 2m11s
tekton-operator-webhook 1/1 1 1 2m10s
2. kubectl get deploy -n tekton-pipelines
NAME READY UP-TO-DATE AVAILABLE AGE
tekton-dashboard 1/1 1 1 103s
tekton-operator-proxy-webhook 1/1 1 1 2m36s
tekton-pipelines-controller 1/1 1 1 2m36s
tekton-pipelines-webhook 1/1 1 1 2m36s
tekton-triggers-controller 1/1 1 1 2m6s
tekton-triggers-core-interceptors 1/1 1 1 2m6s
tekton-triggers-webhook 1/1 1 1 2m6s
2. kubectl get TektonConfig
NAME READY REASON
config True
After installing dashboard, install the ingress:
kubectl apply -f ingress/dashboard-ingress.yaml
kubectl get ingress -n tekton-pipelines
NAME CLASS HOSTS ADDRESS PORTS AGE
tekton-dashboard <none> * 35.193.61.53 80 23s
access dashboard
http://35.193.61.53/dashboard
git clone https://github.com/savitaashture/devconf-cz-tekton-samples/
kubectl create ns demo
kubectl -n demo create secret docker-registry demo-credentials --docker-server=docker.io --docker-username=savita3020 --docker-password=<password>
kubectl -n demo apply -f https://raw.githubusercontent.com/tektoncd/catalog/main/task/openshift-client/0.1/openshift-client.yaml
kubectl -n demo apply -f https://raw.githubusercontent.com/tektoncd/catalog/main/task/buildah/0.2/buildah.yaml
kubectl -n demo apply -f https://raw.githubusercontent.com/tektoncd/catalog/main/task/git-clone/0.4/git-clone.yaml
verify Task creation
kubectl get task -n demo
NAME AGE
buildah 29s
git-clone 20s
openshift-client 34s
kubectl -n demo create -f samples/
verify PipelineRun creation
kubectl get pipelinerun -n demo
NAME SUCCEEDED REASON STARTTIME COMPLETIONTIME
build-deploy-api-pipelinerun-wqjmc True Succeeded 2m32s 57s
kubectl -n demo create -f samples/triggers/
verify EventListener creation
- EventListener Object
kubectl -n demo get el
NAME ADDRESS AVAILABLE REASON READY REASON
github-listener-interceptor http://el-github-listener-interceptor.demo.svc.cluster.local:8080 True MinimumReplicasAvailable True
- Get Pod created by EventListener
kubectl get pods -n demo
NAME READY STATUS RESTARTS AGE
el-github-listener-interceptor-86cf6d886c-wchmx 1/1 Running 0 5m9s
kubectl -n demo create -f ingress/el-ingress.yaml
kubectl get ing -n demo
NAME CLASS HOSTS ADDRESS PORTS AGE
tekton-trigger <none> * 35.193.61.53 80 33s
access EventListener
curl http://35.193.61.53/ci/
Create/reopen a PR for this repository.
kubectl -n demo get pipelinerun | grep build-deploy-api-pipelinerun-
to see the created PipelineRun.