diff --git a/lib/builder-targets.sh b/lib/builder-targets.sh index 6afb0b9..53df44e 100644 --- a/lib/builder-targets.sh +++ b/lib/builder-targets.sh @@ -161,7 +161,7 @@ builder_retrieve() { mkdir -p ${DIST_CACHE_DIR}/$arch DL_DIST_FILE[$i]=${DIST_CACHE_DIR}/$arch/$basename - retrieve_file $downloader $src ${DL_DIST_FILE[$i]} + retrieve_file $downloader $src ${DL_DIST_FILE[$i]} if [ $? != 0 ] ; then echo " Warning: Failed to download file - try next URL" diff --git a/lib/builder-utils.sh b/lib/builder-utils.sh index da37835..22fcd83 100644 --- a/lib/builder-utils.sh +++ b/lib/builder-utils.sh @@ -30,6 +30,7 @@ function retrieve_file() { local downloader=$1 local src=$2 local dst=$3 + local option=$4 # Check, if the URL is a file URL starting with file:// if [ -f $dst ] && [ -z ${DIST_FORCE_DOWNLOAD} ]; then @@ -40,7 +41,7 @@ function retrieve_file() { else rm -f $dst if [ "$downloader" = "wget" ]; then - wget --no-check-certificate --tries=1 -O $dst --timeout=5 -q --no-verbose "$src" + wget --no-check-certificate --header='Cookie: oraclelicense=accept-securebackup-cookie' --tries=1 -O $dst --timeout=5 -q --no-verbose "$src" if [ "$?" == "1" ] ; then rm $dst fi