withKubeConfig支持的是plain credential text因此要建立以下截圖的憑據,不然是沒法鏈接到k8s的,找了很久,看文獻仍是得看原生的。如下截圖就是導入k8s集羣的k8s的config文件就能夠了。git
https://jenkins.io/doc/pipeline/steps/kubernetes-cli/#kubernetes-cli-plugingithub
https://wiki.jenkins.io/display/JENKINS/Plain+Credentials+Plugin3d
https://github.com/jenkinsci/kubernetes-cli-plugin/blob/master/README.mdblog