diff --git a/artifacts/airgap_patch.py b/artifacts/airgap_patch.py index 5a31bf39f..e8ab71764 100644 --- a/artifacts/airgap_patch.py +++ b/artifacts/airgap_patch.py @@ -37,6 +37,7 @@ "cilium_version": ['cilium'], "etcd_version": ['etcd'], "pod_infra_version": ['pause'], + "runc_version": ['runc'], } def file_lines_to_list(filename): @@ -146,7 +147,7 @@ def get_manifest_data(): def get_other_required_keywords(manifest_dict): other_required_keywords = [ - "runc", "crun", "runsc", "cri-dockerd", "yq", "nginx", "k8s-dns-node-cache", "cluster-proportional-autoscaler"] + "crun", "runsc", "cri-dockerd", "yq", "nginx", "k8s-dns-node-cache", "cluster-proportional-autoscaler"] manifest_keys = [ key for key in manifest_dict] keys_range = [ key for key in KEYWORDS] list_diff = list(set(keys_range) - set(manifest_keys)) diff --git a/artifacts/gen_airgap_pkgs.sh b/artifacts/gen_airgap_pkgs.sh index 3676da6a7..02f4048c3 100644 --- a/artifacts/gen_airgap_pkgs.sh +++ b/artifacts/gen_airgap_pkgs.sh @@ -131,8 +131,17 @@ function create_images() { fi echo "begin to download images." + + local images_list_path="${CURRENT_DIR}/kubespray/contrib/offline/temp/images.list" local images_list_content - images_list_content=$(cat "${CURRENT_DIR}/kubespray/contrib/offline/temp/images.list") + + sed -i '/^$/d' "${images_list_path}" + + if [[ ! -s "${images_list_path}" ]]; then + echo "images.list is empty" + return + fi + images_list_content=$(cat "${images_list_path}") rm -rf offline-images && mkdir offline-images