5

I am writing a kickstart file to configure a CentOS 7 installation. I'd like to install some packages from the Fedora EPEL repository, so I'm adding a repo command to the configuration.

I'm having trouble finding the canonical URL I should use for the --mirrorlist option. Where would this be documented?

repo --name=epel --mirrorlist=<which url?>
%packages
# various packages
%end

I didn't see anything listed in the EPEL FAQ and Fedora's mirror manager site just has a bunch of human-readable pages. In addition, the kickstart documentation does not document what the format of a mirror list must be.

2 Answers 2

4

The Fedora Project has some documentation on its mirrorlists on its MirrorManage wiki page.

metalink=http://mirrors.fedoraproject.org/metalink?repo=fedora-10&arch=$basearch

mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=fedora-10&arch=$basearch

I also discovered that the CentOS 7 epel-release package installs a configuration file at /etc/yum.repos.d/epel.repo which had some clues:

[epel]
#baseurl=http://download.fedoraproject.org/pub/epel/7/$basearch
mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-7&arch=$basearch

Anaconda supports substituting $basearch and other variables in a kickstart repo command.

Ultimately I had a lot of trouble with repo commands and was not able to install the epel-release package from kickstart. I gave up and used Packer and Ansible to install packages instead.

1
3

The answer is:

https://mirrors.fedoraproject.org/mirrorlist?repo=epel-7&arch=x86_64

This is just a plain text file, with one URL per line.

By providing invalid entries for the repo and arch parameters, you can get a list of valid entries, including:

# repo=epel-6&arch=i386
# repo=epel-6&arch=ppc64
# repo=epel-6&arch=x86_64
# repo=epel-7&arch=aarch64
# repo=epel-7&arch=ppc64
# repo=epel-7&arch=ppc64le
# repo=epel-7&arch=x86_64

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .