@@ -922,12 +922,20 @@ download_pkg_from_url() {
922922 local __sha256=" $1 " # if set to "--no-checksum", do not check checksum
923923 local __filename=" $2 "
924924 local __url=" $3 "
925+
926+ # Hide the progress bar in containers to prevent flooding output
927+ local DOWNLOADER_FLAGS
928+ if [ -f /.dockerenv ] || [ -f /run/.containerenv ]; then
929+ DOWNLOADER_FLAGS=" --quiet"
930+ else
931+ DOWNLOADER_FLAGS=" --quiet --show-progress"
932+ fi
925933
926934 # Smart certificate validation strategy
927935 case " ${DOWNLOAD_CERT_POLICY:- smart} " in
928936 " strict" )
929937 echo " Downloading with strict certificate validation: $__url "
930- if ! wget --quiet --show-progress ${DOWNLOADER_FLAGS} " $__url " -O " $__filename " ; then
938+ if ! wget ${DOWNLOADER_FLAGS} " $__url " -O " $__filename " ; then
931939 rm -f " $__filename "
932940 report_error " failed to download $__url (strict certificate validation)"
933941 recommend_offline_installation " $__filename " " $__url "
@@ -938,7 +946,7 @@ download_pkg_from_url() {
938946 ;;
939947 " skip" )
940948 echo " Downloading with certificate validation disabled: $__url "
941- if ! wget --quiet --show-progress ${DOWNLOADER_FLAGS} " $__url " -O " $__filename " --no-check-certificate; then
949+ if ! wget ${DOWNLOADER_FLAGS} " $__url " -O " $__filename " --no-check-certificate; then
942950 rm -f " $__filename "
943951 report_error " failed to download $__url "
944952 recommend_offline_installation " $__filename " " $__url "
@@ -950,7 +958,7 @@ download_pkg_from_url() {
950958 " smart" |* )
951959 # Smart fallback: try with certificate validation first, then without
952960 echo " Attempting secure download: $__url "
953- if wget --quiet --show-progress ${DOWNLOADER_FLAGS} " $__url " -O " $__filename " ; then
961+ if wget ${DOWNLOADER_FLAGS} " $__url " -O " $__filename " ; then
954962 echo " Download successful with certificate validation"
955963 else
956964 echo " Certificate validation failed, retrying without certificate check..."
0 commit comments