diskimage-builder/elements/centos7/pre-install.d/01-yum-repos
Wesley Hayutin 7edf0f2a2d update the dib centos7 baseurl to use a mirrorlist
* replace baseurl with a centos mirrorlist
* fix typo in repoid

Change-Id: I028d1d7e9bf0b180ad73f750630adfbe41424512
2015-04-14 22:28:43 +00:00

26 lines
534 B
Bash
Executable File

#!/bin/bash
if [ ${DIB_DEBUG_TRACE:-0} -gt 0 ]; then
set -x
fi
set -eu
set -o pipefail
cat << EOF > /etc/yum.repos.d/centos7-latest.repo
[centos7]
name=centos7
mirrorlist=http://mirrorlist.centos.org/?release=7&arch=\$basearch&repo=os&infra=\$infra
enabled=1
metadata_expire=7d
gpgcheck=0
EOF
cat << EOF > /etc/yum.repos.d/epel.repo
[epel]
name=Extra Packages for Enterprise Linux 7 - \$basearch
mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-7&arch=\$basearch
failovermethod=priority
enabled=1
gpgcheck=0
EOF