145 lines
6.1 KiB
INI
145 lines
6.1 KiB
INI
|
# This is an example ~/.config/optools/repoclone/centos.ini.
|
||
|
# You may need to change some options, but they are all commented so you know
|
||
|
# what to replace.
|
||
|
###############################################################################
|
||
|
# SPECIAL VALUES #
|
||
|
# You may recognize some values as used in yum's repo files
|
||
|
# (i.e. /etc/yum.repos.d/*.repo). THEY ARE NOT THE SAME. You CANNOT and SHOULD
|
||
|
# NOT simply copy-and-paste them in here, as they are constructed/used
|
||
|
# differently.
|
||
|
# That said, the following are special values/variables that are generated
|
||
|
# automatically (*case-sensitive*):
|
||
|
#
|
||
|
# {name}: The name of the repo (i.e. what appears in [brackets]).
|
||
|
# It is best that you leave this set in [DEFAULT] the way it
|
||
|
# is.
|
||
|
#
|
||
|
# {cur_arch}: The current hardware architecture of the host running the
|
||
|
# script e.g. x86_64 or i686.
|
||
|
#
|
||
|
# {rel_ver}: The release version. This will substitute for each version
|
||
|
# in the repository's "releases" directive. For example:
|
||
|
#
|
||
|
# destination = /srv/repos/centos/{rel_ver}/os/x86_64
|
||
|
# releases = 6,7
|
||
|
# baseuri = mirrors.centos.org/{rel_ver}/os/x86_64
|
||
|
#
|
||
|
# would clone from the following to the following:
|
||
|
#
|
||
|
# mirrors.centos.org/6/os/x86_64 =>
|
||
|
# /srv/repos/centos/6/os/x86_64
|
||
|
#
|
||
|
# mirrors.centos.org/7/os/x86_64 =>
|
||
|
# /srv/repos/centos/7/os/x86_64
|
||
|
#
|
||
|
# {arch}: Similar to {rel_ver} in that it iterates, but for each item
|
||
|
# in the "arches" directive.
|
||
|
#
|
||
|
# {cur_ver}: *IF* (and *only* if) you are running this script on CentOS
|
||
|
# itself, this will be a "meta-variable" containing the full
|
||
|
# version, major version, minor version, and revision.
|
||
|
# i.e. For CentOS 7.4.1708, {cur_ver} or {cur_ver.full} will
|
||
|
# both replace as "7.4.1708". {cur_ver.maj} will replace as
|
||
|
# "7", {cur.min} will replace as "4", and {cur.rev} will
|
||
|
# replace as "1708". If you use this mechanism and are NOT
|
||
|
# running the script on CentOS, an error will occur.
|
||
|
#
|
||
|
# You can also refer to directives themselves -- see below for an example of
|
||
|
# this.
|
||
|
###############################################################################
|
||
|
# The default section provides... well, defaults. All of these values can be
|
||
|
# overridden in each repository defined. If any of these are not specified,
|
||
|
# either in DEFAULT or in the repo section itself, then an error will occur.
|
||
|
[DEFAULT]
|
||
|
|
||
|
# The name of the repository. By default, this (repo_name) is the name of the
|
||
|
# section.
|
||
|
# {name} will ALWAYS be the section name and cannot be changed.
|
||
|
repo_name = {name}
|
||
|
|
||
|
# Whether we should sync this repository or not.
|
||
|
# To enable a repository, set this to one of: 1, yes, on, true
|
||
|
# To disable a repository, set this to one of: 0, no, off, false
|
||
|
enabled = 0
|
||
|
|
||
|
# The list of architectures to clone, separated by commas (if you have more
|
||
|
# than one). This is iterated over.
|
||
|
arches = i686,{arch}
|
||
|
|
||
|
# The full path to the "base" of the repository where we'll be rsyncing from.
|
||
|
# As shown, if an "$" is in front of curly brackets, you can use another
|
||
|
# directive in the same section. To specify a directive from another section,
|
||
|
# you would use ${section:directive} (e.g. ${base:repo_name})
|
||
|
# Note that this has the potential to generate multiple iterations.
|
||
|
# isomirrors_sort.py should offer package repository mirrors as well, so that
|
||
|
# may be handy to find a fast mirror.
|
||
|
# Note that the default probably will not work for you since you need to be
|
||
|
# whitelisted to use it.
|
||
|
baseuri = mirror.centos.org/centos/{rel_ver}/${repo_name}/{arch}
|
||
|
|
||
|
# Where the clone should go. If you are using iterables, make sure you use them
|
||
|
# here, too, otherwise you'll most likely overwrite parts and end up with a
|
||
|
# totally broken repository!
|
||
|
# The parent directories will be created if necessary (assuming we have proper
|
||
|
# permissions).
|
||
|
destination = ${mount}/centos/{rel_ver}/${repo_name}/{arch}
|
||
|
|
||
|
# Perform a check before we start to make sure this mountpoint has a device
|
||
|
# mounted at it. If you don't store your repository mirrors at a different
|
||
|
# mountpoint, just set this to "/" (without quotes).
|
||
|
mount = /mnt/repos
|
||
|
|
||
|
# If set, throttle the transfer speeds down to this number of Kilobytes per
|
||
|
# second (KB/s, *not* kbps!).
|
||
|
# If it's set to 0, don't perform any throttling.
|
||
|
bwlimit = 0
|
||
|
|
||
|
# The lockfile for the repository. If this file is present, the clone will
|
||
|
# abort to avoid rsync/file differentiation conflicts. The parent directories
|
||
|
# will be created if necessary (assuming we have proper permissions).
|
||
|
lockfile = /var/run/repo-sync_{name}.lck
|
||
|
|
||
|
# The logfile for this repository. The parent directories will be created if
|
||
|
# necessary (assuming we have proper permissions).
|
||
|
logfile = /var/log/repo/centos.log
|
||
|
|
||
|
# The releases to clone for. Note that we follow symlinks, so you should *NOT*
|
||
|
# include e.g. both 7 and 7.4.1708. This is also an iterable in the form of a
|
||
|
# comma-separated list (if you have more than one).
|
||
|
releases = 6,{cur_ver.maj}
|
||
|
|
||
|
# A comma-separated list of paths/patterns on the rsync server to exclude (if
|
||
|
# you have more than one). Leave empty for no excludes (this should be fine if
|
||
|
# your "baseuri"s are explicit enough).
|
||
|
excludes =
|
||
|
|
||
|
# This would be equivalent to cloning the [base] repository found in
|
||
|
# /etc/yum.repos.d/CentOS-Base.repo
|
||
|
[base]
|
||
|
repo_name = os
|
||
|
enabled = 1
|
||
|
|
||
|
# Likewise with [base], but with [updates] instead, etc.
|
||
|
[updates]
|
||
|
enabled = 1
|
||
|
|
||
|
[extras]
|
||
|
enabled = 1
|
||
|
|
||
|
[centosplus]
|
||
|
enabled = 1
|
||
|
|
||
|
# /etc/yum.repos.d/epel.repo (assuming you installed the epel-release package)
|
||
|
# Just like CentOS mirrors, you probably need to change this since they run a
|
||
|
# whitelist.
|
||
|
[epel]
|
||
|
enabled = 1
|
||
|
baseuri = dl.fedoraproject.org::fedora-{name}0/{rel_ver}/{arch}
|
||
|
destination = ${mount}/centos/{name}/{rel_ver}/{arch}
|
||
|
|
||
|
# It even works with non-RedHat-supplied repositories, too! As long as they
|
||
|
# offer rsync access. I *highly* recommend you check IUS out: https://ius.io/
|
||
|
[ius]
|
||
|
enabled = 0
|
||
|
baseuri = dl.iuscommunity.org/{name}/stable/CentOS/{rel_ver}/{arch}
|