tekton安装篇

2020-06-14  本文已影响0人  香葱煎蛋饼

tekton属于原云生的CICD工具,原属于Knative的build组件,后剥离出来作为独立的CICD工具。

github地址:https://github.com/tektoncd/pipeline

在线试用体验地址:https://tekton.dev/try

环境说明:

kubenetes: 1.18

tekton: 0.13.2

1.安装

具体安装环境要求和细节,请查考官网,下面主要介绍安装步骤,一句命令如下:

# kubectl apply --filename https://storage.googleapis.com/tekton-releases/pipeline/latest/release.yaml

上面是安装最新版本,我这里安装0.13.2,可以用下面命令安装指定版本

# kubectl apply --filename https://storage.googleapis.com/tekton-releases/pipeline/previous/v0.13.2/release.yaml

由于官网上镜像地址在外国,我把镜像上传到了docker hub,并改写了release.yaml文件,所以可用下面命令创建

# kubectl apply -f https://raw.githubusercontent.com/LGTH/rawfile/master/tekton-v0.13.2.yaml

验证是否成功:

# kubectl get pods -n tekton-pipelines
NAME                                           READY   STATUS    RESTARTS   AGE
tekton-pipelines-controller-6db684f4b7-v9z4t   1/1     Running   0          18s
tekton-pipelines-webhook-89f89cd5-f9klb        1/1     Running   0          17s

安装triggers触发器,换成国内镜像后,安装如下:

# kubectl apply -f https://raw.githubusercontent.com/LGTH/rawfile/master/tekton-trigger-0.5.0.yaml

验证触发器是否安装成功

# kubectl get pods --namespace tekton-pipelines 
NAME                                           READY   STATUS    RESTARTS   AGE
tekton-pipelines-controller-6db684f4b7-v9z4t   1/1     Running   0          65m
tekton-pipelines-webhook-89f89cd5-f9klb        1/1     Running   0          65m
tekton-triggers-controller-85855674d5-lq67b    1/1     Running   0          49s
tekton-triggers-webhook-57f5854fbb-njd9b       1/1     Running   0          48s

安装dashboard,换成国内镜像,安装如下:

# kubectl apply -f https://raw.githubusercontent.com/LGTH/rawfile/master/tekton-dashboard-0.7.0.yaml

验证dashboard

# kubectl get pods --namespace tekton-pipelines 
NAME                                           READY   STATUS    RESTARTS   AGE
tekton-dashboard-59cdc76944-f2bs9              1/1     Running   0          8s
tekton-pipelines-controller-6db684f4b7-v9z4t   1/1     Running   0          77m
tekton-pipelines-webhook-89f89cd5-f9klb        1/1     Running   0          77m
tekton-triggers-controller-85855674d5-lq67b    1/1     Running   0          12m
tekton-triggers-webhook-57f5854fbb-njd9b       1/1     Running   0          12m

可以利用port-forward,在本地转发

# kubectl --namespace tekton-pipelines port-forward --address 0.0.0.0 svc/tekton-dashboard 9097:9097

在浏览器中打开 http://localhost:9097 网址

image-20200614172647755.png
上一篇 下一篇

猜你喜欢

热点阅读