[PATCH lkp-tests 2/3] fix(iso2rootfs): the ip of the newest openeuler iso url has changed

The ip of the newest openeuler iso url has changed from the public ip to the internal ip. So replace it while running. Signed-off-by: Yu Chuan <13186087857@163.com> --- tests/iso2rootfs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/iso2rootfs b/tests/iso2rootfs index b60a82a7c972..735c2b9aabcd 100755 --- a/tests/iso2rootfs +++ b/tests/iso2rootfs @@ -59,6 +59,10 @@ check_yaml_vars() get_daily_iso_checksum() { ISO_URL="$(curl "${iso_url_file}")" + [ "${iso_os}" == "openeuler" ] && { + local pub_ip=$(echo "${iso_url_file}" | grep -oEw "[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}") + ISO_URL="$(curl "${iso_url_file}" |sed -r "s/[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}/${pub_ip}/g")" + } ISO_NAME=$(basename "$ISO_URL") ISO_CHECKSUM_URL="${ISO_URL}.sha256sum" -- 2.23.0
participants (1)
-
Yu Chuan