Merge "Add support for Fedora 28, remove EOL Fedora 26"

This commit is contained in:
Zuul 2018-10-18 23:44:51 +00:00 committed by Gerrit Code Review
commit 46ec4992ff
7 changed files with 28 additions and 12 deletions

View File

@ -42,7 +42,7 @@ cat <<EOF > $FEDORA_MIN_DIR/dib-mirror-fedora-updates.repo
[updates]
name=Fedora \$releasever - \$basearch - Updates
failovermethod=priority
baseurl=$NODEPOOL_FEDORA_MIRROR/updates/\$releasever/\$basearch/
baseurl=$NODEPOOL_FEDORA_MIRROR/updates/\$releasever/Everything/\$basearch/
enabled=1
gpgcheck=0
metadata_expire=6h

View File

@ -1,2 +1,2 @@
export DISTRO_NAME=fedora
export DIB_RELEASE=${DIB_RELEASE:-27}
export DIB_RELEASE=${DIB_RELEASE:-28}

View File

@ -1,7 +1,7 @@
[fedora]
name=Fedora $releasever - $basearch
failovermethod=priority
#baseurl=http://download.fedoraproject.org/pub/fedora/linux/releases/$releasever/Everything/$basearch/os/
#baseurl=http://download.fedoraproject.org/pub/fedora/linux/releases/$releasever/Everything/$basearch/os
metalink=https://mirrors.fedoraproject.org/metalink?repo=fedora-$releasever&arch=$basearch
gpgcheck=0
skip_if_unavailable=False
@ -9,7 +9,7 @@ skip_if_unavailable=False
[updates]
name=Fedora $releasever - $basearch - Updates
failovermethod=priority
#baseurl=http://download.fedoraproject.org/pub/fedora/linux/updates/$releasever/$basearch/
#baseurl=http://download.fedoraproject.org/pub/fedora/linux/updates/$releasever/Everything/$basearch/
metalink=https://mirrors.fedoraproject.org/metalink?repo=updates-released-f$releasever&arch=$basearch
enabled=1
gpgcheck=0

View File

@ -1,5 +1,5 @@
export DISTRO_NAME=fedora
export DIB_RELEASE=${DIB_RELEASE:-27}
export DIB_RELEASE=${DIB_RELEASE:-28}
# Note the filename URL has a "sub-release" in it
# http:// ... Fedora-Cloud-Base-25-1.3.x86_64.qcow2
@ -11,10 +11,10 @@ export DIB_RELEASE=${DIB_RELEASE:-27}
#
# [1] https://lists.fedoraproject.org/archives/list/cloud@lists.fedoraproject.org/thread/2WFO2FKIGUQYRQXIR35UVJGRHF7LQENJ/
if [[ ${DIB_RELEASE} == '26' ]]; then
export DIB_FEDORA_SUBRELEASE=1.5
elif [[ ${DIB_RELEASE} == '27' ]]; then
if [[ ${DIB_RELEASE} == '27' ]]; then
export DIB_FEDORA_SUBRELEASE=1.6
elif [[ ${DIB_RELEASE} == '28' ]]; then
export DIB_FEDORA_SUBRELEASE=1.1
else
echo "Unsupported Fedora release"
exit 1

View File

@ -10,6 +10,14 @@ DIB_DISTRIBUTION_MIRROR=${DIB_DISTRIBUTION_MIRROR:-}
[ -n "$DIB_DISTRIBUTION_MIRROR" ] || exit 0
if [[ ${DIB_RELEASE} -gt 27 ]]; then
# urgh, the repo is wrong in the "baseurl" line, see
# https://pagure.io/fedora/repos/issue/70
for FILE in /etc/yum.repos.d/fedora-updates.repo /etc/yum.repos.d/fedora-updates-testing.repo; do
sed -i "s|/os/||" $FILE
done
fi
for FILE in /etc/yum.repos.d/fedora.repo /etc/yum.repos.d/fedora-updates.repo /etc/yum.repos.d/fedora-updates-testing.repo; do
sudo sed -e "s|^#baseurl=http://download.fedoraproject.org/pub/fedora/linux|baseurl=$DIB_DISTRIBUTION_MIRROR|;/^metalink/d" -i $FILE
done

View File

@ -26,10 +26,18 @@ else
# note default DIB_RELEASE set in environment setup
case ${ARCH} in
x86_64)
DIB_CLOUD_IMAGES=${DIB_CLOUD_IMAGES:-https://download.fedoraproject.org/pub/fedora/linux/releases/${DIB_RELEASE}/CloudImages/${ARCH}/images}
if [[ ${DIB_RELEASE} -ge 28 ]]; then
DIB_CLOUD_IMAGES=${DIB_CLOUD_IMAGES:-https://download.fedoraproject.org/pub/fedora/linux/releases/${DIB_RELEASE}/Cloud/${ARCH}/images}
else
DIB_CLOUD_IMAGES=${DIB_CLOUD_IMAGES:-https://download.fedoraproject.org/pub/fedora/linux/releases/${DIB_RELEASE}/CloudImages/${ARCH}/images}
fi
;;
aarch64|ppc64|ppc64le)
DIB_CLOUD_IMAGES=${DIB_CLOUD_IMAGES:-https://dl.fedoraproject.org/pub/fedora-secondary/releases/${DIB_RELEASE}/CloudImages/${ARCH}/images}
if [[ ${DIB_RELEASE} -ge 28 ]]; then
DIB_CLOUD_IMAGES=${DIB_CLOUD_IMAGES:-https://dl.fedoraproject.org/pub/fedora-secondary/releases/${DIB_RELEASE}/Cloud/${ARCH}/images}
else
DIB_CLOUD_IMAGES=${DIB_CLOUD_IMAGES:-https://dl.fedoraproject.org/pub/fedora-secondary/releases/${DIB_RELEASE}/CloudImages/${ARCH}/images}
fi
;;
*)
echo "Error: unknown ARCH: ${ARCH}"

View File

@ -5,7 +5,7 @@ Distributions which are supported as a build host:
- Centos 6, 7
- Debian 8 ("jessie")
- Fedora 26, 27
- Fedora 27, 28
- RHEL 6, 7
- Ubuntu 14.04 ("trusty")
- Gentoo
@ -16,7 +16,7 @@ Distributions which are supported as a target for an image:
- Centos 6, 7
- Debian 8 ("jessie")
- Fedora 26, 27
- Fedora 27, 28
- RHEL 6, 7
- Ubuntu 12.04 ("precise"), 14.04 ("trusty")
- Gentoo