创建部署问题时,请参考下面模板,你提供的信息越多,越容易及时获得解答。如果未按模板创建问题,管理员有权关闭问题。
确保帖子格式清晰易读,用 markdown code block 语法格式化代码块。
你只花一分钟创建的问题,不能指望别人花上半个小时给你解答。
操作系统信息
例如:虚拟机,Ubuntu22.04,4C/8G
Kubernetes版本信息
将 kubectl version
命令执行结果贴在下方
v1.21.5
容器运行时
将 docker version
/ crictl version
/ nerdctl version
结果贴在下方
containerd 1.6.4
KubeSphere版本信息
例如:v2.1.1/v3.0.0。离线安装还是在线安装。在已有K8s上安装还是使用kk安装。
v3.3.0
问题是什么
报错日志是什么,最好有截图。
root@ubuntu:/data/kubesphere/v3.3.0# kk artifact image push -f config-sample.yaml -a kubekey-artifact.tar.gz
_ __ _ _ __
| | / / | | | | / /
| |/ / _ _| |__ ___| |/ / ___ _ _
| \| | | | '_ \ / _ \ \ / _ \ | | |
| |\ \ |_| | |_) | __/ |\ \ __/ |_| |
\_| \_/\__,_|_.__/ \___\_| \_/\___|\__, |
__/ |
|___/
13:17:35 CST [GreetingsModule] Greetings
13:17:35 CST message: [node2]
Greetings, KubeKey!
13:17:36 CST message: [node1]
Greetings, KubeKey!
13:17:36 CST success: [node2]
13:17:36 CST success: [node1]
13:17:36 CST [UnArchiveArtifactModule] Check the KubeKey artifact md5 value
13:17:37 CST success: [LocalHost]
13:17:37 CST [UnArchiveArtifactModule] UnArchive the KubeKey artifact
13:17:37 CST skipped: [LocalHost]
13:17:37 CST [UnArchiveArtifactModule] Create the KubeKey artifact Md5 file
13:17:37 CST skipped: [LocalHost]
13:17:37 CST [CopyImagesToRegistryModule] Copy images to a private registry from an artifact OCI Path
13:17:37 CST Source: oci:/data/kubesphere/v3.3.0/kubekey/images:calico:cni:v3.20.0-amd64
13:17:37 CST Destination: docker://192.168.72.15/kubesphereio/cni:v3.20.0-amd64
Getting image source signatures
13:17:37 CST message: [LocalHost]
copy image oci:/data/kubesphere/v3.3.0/kubekey/images:calico:cni:v3.20.0-amd64 to docker://192.168.72.15/kubesphereio/cni:v3.20.0-amd64 failed: trying to reuse blob sha256:a97babae0e73ac29ec5136a8c71a6feda9c92e423775ea8ef2315f1c4af537a5 at destination: pinging container registry 192.168.72.15: Get "https://192.168.72.15/v2/": dial tcp 192.168.72.15:443: connect: connection refused
13:17:37 CST failed: [LocalHost]
error: Pipeline[ArtifactImagesPushPipeline] execute failed: Module[CopyImagesToRegistryModule] exec failed:
failed: [LocalHost] [CopyImagesToRegistry] exec failed after 1 retires: copy image oci:/data/kubesphere/v3.3.0/kubekey/images:calico:cni:v3.20.0-amd64 to docker://192.168.72.15/kubesphereio/cni:v3.20.0-amd64 failed: trying to reuse blob sha256:a97babae0e73ac29ec5136a8c71a6feda9c92e423775ea8ef2315f1c4af537a5 at destination: pinging container registry 192.168.72.15: Get "https://192.168.72.15/v2/": dial tcp 192.168.72.15:443: connect: connection refused
config-sample.yaml配置
apiVersion: kubekey.kubesphere.io/v1alpha2
kind: Cluster
metadata:
name: sample
spec:
hosts:
- {name: node1, address: 192.168.72.40, internalAddress: 192.168.72.40, user: root, password: "123456"}
- {name: node2, address: 192.168.72.41, internalAddress: 192.168.72.41, user: root, password: "123456"}
- {name: node3, address: 192.168.72.42, internalAddress: 192.168.72.42, user: root, password: "123456"}
roleGroups:
etcd:
- node1
control-plane:
- node1
worker:
- node1
- node2
controlPlaneEndpoint:
domain: lb.kubesphere.local
address: ""
port: 6443
kubernetes:
version: v1.21.5
clusterName: cluster.local
autoRenewCerts: true
containerManager: containerd
etcd:
type: kubekey
network:
plugin: calico
kubePodsCIDR: 10.233.64.0/18
kubeServiceCIDR: 10.233.0.0/18
multusCNI:
enabled: false
registry:
privateRegistry: "192.168.72.15"
auths:
"192.168.72.15":
username: admin
password: Harbor12345
namespaceOverride: "kubesphereio"
registryMirrors: []
insecureRegistries: ["192.168.72.15"]
addons: []
docker 配置
root@ubuntu:/data/kubesphere/v3.3.0# cat /etc/docker/daemon.json
{
"registry-mirrors": ["https://uyah70su.mirror.aliyuncs.com"],
"insecure-registries": ["192.168.72.50:5000","192.168.72.15"],
"live-restore": true
}
镜像仓库已创建
root@ubuntu:/data/kubesphere/v3.3.0# bash create_project_harbor.sh
creating library
creating kubesphere
creating calico
creating coredns
creating openebs
creating csiplugin
creating minio
creating mirrorgooglecontainers
creating osixia
creating prom
creating thanosio
creating jimmidyson
creating grafana
creating elastic
creating istio
creating jaegertracing
creating jenkins
creating weaveworks
creating openpitrix
creating joosthofman
creating nginxdemos
creating fluent
creating kubeedge