Merge pull request #533 from marineam/https

*: convert assorted download references to https
This commit is contained in:
Michael Marineau 2016-05-02 20:24:19 -07:00
commit bfb5618261
5 changed files with 13 additions and 7 deletions

View File

@ -54,6 +54,11 @@ EOF
catalyst_stage_default
}
# Switch to HTTP because early boostrap stages do not have SSL support.
GENTOO_MIRRORS=$(portageq envvar GENTOO_MIRRORS)
GENTOO_MIRRORS="${GENTOO_MIRRORS//https:\/\//http://}"
export GENTOO_MIRRORS
catalyst_init "$@"
check_gsutil_opts

View File

@ -77,6 +77,7 @@ export MAKEOPTS='--jobs=${NUM_JOBS} --load-average=${load}'
export EMERGE_DEFAULT_OPTS="\$MAKEOPTS"
export PORTAGE_USERNAME=portage
export PORTAGE_GRPNAME=portage
export GENTOO_MIRRORS='$(portageq envvar GENTOO_MIRRORS)'
EOF
}

View File

@ -57,10 +57,10 @@ IMAGE_NAME="${RAW_IMAGE_NAME}.bz2"
DIGESTS_NAME="${IMAGE_NAME}.DIGESTS.asc"
case ${VERSION_ID} in
stable) BASE_URL="http://stable.release.core-os.net/amd64-usr/current" ;;
alpha) BASE_URL="http://alpha.release.core-os.net/amd64-usr/current" ;;
beta) BASE_URL="http://beta.release.core-os.net/amd64-usr/current" ;;
*) BASE_URL="http://storage.core-os.net/coreos/amd64-usr/${VERSION_ID}" ;;
stable) BASE_URL="https://stable.release.core-os.net/amd64-usr/current" ;;
alpha) BASE_URL="https://alpha.release.core-os.net/amd64-usr/current" ;;
beta) BASE_URL="https://beta.release.core-os.net/amd64-usr/current" ;;
*) BASE_URL="https://alpha.release.core-os.net/amd64-usr/${VERSION_ID}" ;;
esac
IMAGE_URL="${BASE_URL}/${IMAGE_NAME}"

View File

@ -15,7 +15,7 @@ release=${1:-"alpha"}
# If the argument is in the form http* allow for watching an arbitrary location
if [[ $1 != http* ]]; then
url="http://storage.core-os.net/coreos/amd64-usr/$release/version.txt"
url="https://${release}.release.core-os.net/amd64-usr/current/version.txt"
else
url=$1
release=$(echo ${url} | sed -e 's/http:\/\///1' -e 's/\//-/g' )

View File

@ -14,13 +14,13 @@ set -e -o pipefail
release=${1:-"alpha"}
if [[ "$1" != http* ]]; then
baseurl="http://${release}.release.core-os.net/amd64-usr/current"
baseurl="https://${release}.release.core-os.net/amd64-usr/current"
else
# for this convoluded trick, we take an arbitrary URL, chop it up, and try
# to turn it into usable input for the rest of the script.
# this is based on urls of the form:
# http://storage.core-os.net/coreos/amd64-usr/master/version.txt
# https://storage.core-os.net/coreos/amd64-usr/master/version.txt
# where the following sed expression extracts the "master" portion
baseurl="${1%/*}"
release="${baseurl##*/}"