From 4c2c755eb7dc2332c3425a6c659a24af56b04a71 Mon Sep 17 00:00:00 2001 From: pixiake Date: Thu, 15 Aug 2024 19:14:13 +0800 Subject: [PATCH] fix: push manifest failed if private registry contian multi-path (#2362) Signed-off-by: pixiake --- cmd/kk/pkg/images/tasks.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/kk/pkg/images/tasks.go b/cmd/kk/pkg/images/tasks.go index d341a3847..50fe114d5 100644 --- a/cmd/kk/pkg/images/tasks.go +++ b/cmd/kk/pkg/images/tasks.go @@ -380,8 +380,8 @@ func (p *PushManifest) Execute(_ connector.Runtime) error { auths := registry.DockerRegistryAuthEntries(p.KubeConf.Cluster.Registry.Auths) auth := new(registry.DockerRegistryEntry) - if _, ok := auths[p.KubeConf.Cluster.Registry.PrivateRegistry]; ok { - auth = auths[p.KubeConf.Cluster.Registry.PrivateRegistry] + if _, ok := auths[p.KubeConf.Cluster.Registry.GetHost()]; ok { + auth = auths[p.KubeConf.Cluster.Registry.GetHost()] } for imageName, platforms := range list {