Skip to content

Commit

Permalink
Merge pull request #1312 from ErikJiang/upd_kylin_iso_url
Browse files Browse the repository at this point in the history
update kylin iso repo urls
  • Loading branch information
ErikJiang authored Jul 17, 2024
2 parents 0ba1e97 + c205508 commit 1ff62e7
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 15 deletions.
28 changes: 21 additions & 7 deletions artifacts/import_iso.sh
Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,27 @@ function iso::mk_server_path() {
fi
fi
if [ -f "$path" ]; then
if echo "$path" | grep 'ky10.x86_64.rpm' >/dev/null 2>&1; then
echo "/kylin-iso/10/os/x86_64"
return
fi
if echo "$path" | grep 'ky10.aarch64.rpm' >/dev/null 2>&1; then
echo "/kylin-iso/10/os/aarch64"
return

if [[ "$(basename $path)" = ".productinfo" ]]; then
# release V10(SP2)/(Sword)-aarch64-Build09/20210524
if grep -q "SP2" $path; then
if grep -q "aarch64" $path; then
echo "/kylin-iso/10/sp2/os/aarch64"
return
else
echo "/kylin-iso/10/sp2/os/x86_64"
return
fi
# release V10 SP3 2403/(Halberd)-aarch64-Build20/20240426
elif grep -q "SP3" $path; then
if grep -q "aarch64" $path; then
echo "/kylin-iso/10/sp3/os/aarch64"
return
else
echo "/kylin-iso/10/sp3/os/x86_64"
return
fi
fi
fi
if [ "$(basename $path)" = ".treeinfo" ]; then
local arch=$(sed -n '/^\[general\]/,$p' $path | sed -n 's/arch = //p' | head -1)
Expand Down
16 changes: 8 additions & 8 deletions hack/resouce_util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -508,10 +508,10 @@ function resource::import_iso_local_path_check(){
function resource::check_iso_file_minio(){
file_list=( "${MINIO_URL}/kubean/centos-iso/7/os/x86_64/Packages/389-ds-base-1.3.10.2-16.el7_9.x86_64.rpm" \
"${MINIO_URL}/kubean/centos-iso/7/os/x86_64/Packages/zziplib-0.13.62-12.el7.x86_64.rpm" \
"${MINIO_URL}/kubean/kylin-iso/10/os/aarch64/Packages/abattis-cantarell-fonts-0.201-1.ky10.noarch.rpm" \
"${MINIO_URL}/kubean/kylin-iso/10/os/aarch64/Packages/zziplib-help-0.13.69-6.ky10.noarch.rpm" \
"${MINIO_URL}/kubean/kylin-iso/10/os/aarch64/repodata/13df713badb6a33bf7517dcee436d2a565773d5035f980b8e84520bc4f7d1c50-filelists.xml.gz" \
"${MINIO_URL}/kubean/kylin-iso/10/os/aarch64/repodata/TRANS.TBL"
"${MINIO_URL}/kubean/kylin-iso/10/sp2/os/aarch64/Packages/abattis-cantarell-fonts-0.201-1.ky10.noarch.rpm" \
"${MINIO_URL}/kubean/kylin-iso/10/sp2/os/aarch64/Packages/zziplib-help-0.13.69-6.ky10.noarch.rpm" \
"${MINIO_URL}/kubean/kylin-iso/10/sp2/os/aarch64/repodata/13df713badb6a33bf7517dcee436d2a565773d5035f980b8e84520bc4f7d1c50-filelists.xml.gz" \
"${MINIO_URL}/kubean/kylin-iso/10/sp2/os/aarch64/repodata/TRANS.TBL"
)
resource::check_files_url_exist "${file_list[@]}"
}
Expand All @@ -522,10 +522,10 @@ function resource::check_iso_file_local_path(){
file_list=( "centos-iso/7/os/x86_64/Packages/389-ds-base-1.3.10.2-16.el7_9.x86_64.rpm" \
"centos-iso/7/os/x86_64/Packages/zziplib-0.13.62-12.el7.x86_64.rpm" \

"kylin-iso/10/os/aarch64/Packages/abattis-cantarell-fonts-0.201-1.ky10.noarch.rpm" \
"kylin-iso/10/os/aarch64/Packages/zziplib-help-0.13.69-6.ky10.noarch.rpm" \
"kylin-iso/10/os/aarch64/repodata/13df713badb6a33bf7517dcee436d2a565773d5035f980b8e84520bc4f7d1c50-filelists.xml.gz" \
"kylin-iso/10/os/aarch64/repodata/TRANS.TBL" )
"kylin-iso/10/sp2/os/aarch64/Packages/abattis-cantarell-fonts-0.201-1.ky10.noarch.rpm" \
"kylin-iso/10/sp2/os/aarch64/Packages/zziplib-help-0.13.69-6.ky10.noarch.rpm" \
"kylin-iso/10/sp2/os/aarch64/repodata/13df713badb6a33bf7517dcee436d2a565773d5035f980b8e84520bc4f7d1c50-filelists.xml.gz" \
"kylin-iso/10/sp2/os/aarch64/repodata/TRANS.TBL" )
for item in "${file_list[@]}"; do
if [[ ! -f ${father_path}/${item} ]];then
echo "Error: ${item} not exist in local path ${father_path}"
Expand Down

0 comments on commit 1ff62e7

Please sign in to comment.