mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-22 19:31:44 +00:00
cluster: configure: load images and add tags with no arch
This commit is contained in:
parent
416a717eff
commit
438ff151d4
@ -381,6 +381,15 @@ function load-docker-images {
|
||||
else
|
||||
try-load-docker-image "${img_dir}/kube-proxy.tar"
|
||||
fi
|
||||
# When we load from a docker archive, the image is tagged with the arch, we don't have docker manifests here.
|
||||
# The resource manifest is expecting something like 'registry/kube-controller-manager:v1.2.3', no arch specified.
|
||||
local -r images=$(docker images --format "{{.Repository}}:{{.Tag}}" | egrep 'kube-apiserver|kube-controller-manager|kube-scheduler|kube-proxy' | grep amd64)
|
||||
for image in $images ; do
|
||||
local -r manifest_name="${image/-amd64/}"
|
||||
if ! docker images --format "{{.Repository}}:{{.Tag}}" | grep -q ${manifest_name} ; then
|
||||
docker tag $image $manifest_name
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
||||
# Downloads kubernetes binaries and kube-system manifest tarball, unpacks them,
|
||||
|
Loading…
Reference in New Issue
Block a user