#!/bin/bash

ls . | grep -v load-images.sh > /tmp/k8s-images.txt

for i in $( cat  /tmp/k8s-images.txt )
do
    docker load -i $i
done

rm -rf /tmp/k8s-images.txt

cd /root/k8s-install/DIR_NAME && sh /root/k8s-install/DIR_NAME/load-images.sh

等同于

ls *.tar | xargs -i docker load -i {}

Logo

K8S/Kubernetes社区为您提供最前沿的新闻资讯和知识内容

更多推荐