You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
lurui 4aa62ab126 fix:debug 6 hours ago
doc/参考模板 fix: client-go ==> 0.20.0 5 days ago
k8s fix:debug 6 hours ago
keywords fix: client-go ==> 0.20.0 5 days ago
logger 初版 3 weeks ago
pkg/lib-qiankun fix:debug 6 hours ago
test fix:add busybox_deploy 2 days ago
.gitignore fix: client-go ==> 0.20.0 5 days ago
README.md fix: client-go ==> 0.20.0 5 days ago
go.mod fix: client-go ==> 0.20.0 5 days ago
go.sum fix: client-go ==> 0.20.0 5 days ago
main.go fix: client-go ==> 0.20.0 5 days ago

README.md

容器库

作用

通过对client-go的二次封装,提供便于创建Deployment、Service以及Ingress等资源的创建/更新的公共方法库。

使用

入口

 pkg/lib-qiankun/k8s.go下的QianKunCreateOrUpdate方法

函数原型

 QianKunCreateOrUpdate(apiHost string, bearerToken string, devSrc string, component string)

参数解析

 apiHost: k8s集群入口地址,例如:https://kubernetes.docker.internal:6443
 bearerToken: 对应k8s集群,具有创建和更新Deployment、Service以及Ingress等资源权限的sa的secret的token值(不需要加Bearer )
 devSrc: 创建或更新对应资源的请求参数,json格式,所需参数参考k8s目录下public_struct下对应资源结构体,或者参考test目录下params.json文件对应部分
 component:创建或更新的资源,例如:deployment,service,ingress