mirror of
https://github.com/saltstack/salt-bootstrap.git
synced 2025-04-16 09:40:21 +00:00
fix indentation, remove unnecessary IFS changes
This commit is contained in:
parent
f82cf912ad
commit
b6272a1b34
1 changed files with 3 additions and 9 deletions
|
@ -4121,18 +4121,15 @@ __install_saltstack_rhel_repository() {
|
||||||
# Instead, this should work correctly on all RHEL variants.
|
# Instead, this should work correctly on all RHEL variants.
|
||||||
base_url="${HTTP_VAL}://${_REPO_URL}/${__PY_VERSION_REPO}/redhat/${DISTRO_MAJOR_VERSION}/\$basearch/${repo_rev}/"
|
base_url="${HTTP_VAL}://${_REPO_URL}/${__PY_VERSION_REPO}/redhat/${DISTRO_MAJOR_VERSION}/\$basearch/${repo_rev}/"
|
||||||
if [ "${DISTRO_MAJOR_VERSION}" -eq 7 ]; then
|
if [ "${DISTRO_MAJOR_VERSION}" -eq 7 ]; then
|
||||||
gpg_key="SALTSTACK-GPG-KEY.pub,base/RPM-GPG-KEY-CentOS-7"
|
gpg_key="SALTSTACK-GPG-KEY.pub base/RPM-GPG-KEY-CentOS-7"
|
||||||
else
|
else
|
||||||
gpg_key="SALTSTACK-GPG-KEY.pub"
|
gpg_key="SALTSTACK-GPG-KEY.pub"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
Field_Separator=$IFS
|
|
||||||
IFS=,
|
|
||||||
gpg_key_urls=""
|
gpg_key_urls=""
|
||||||
for key in $gpg_key; do
|
for key in $gpg_key; do
|
||||||
gpg_key_urls=$(printf "${base_url}${key},%s" "$gpg_key_urls")
|
gpg_key_urls=$(printf "${base_url}${key},%s" "$gpg_key_urls")
|
||||||
done
|
done
|
||||||
IFS=$Field_Separator
|
|
||||||
|
|
||||||
repo_file="/etc/yum.repos.d/salt.repo"
|
repo_file="/etc/yum.repos.d/salt.repo"
|
||||||
|
|
||||||
|
@ -4149,12 +4146,9 @@ enabled_metadata=1
|
||||||
_eof
|
_eof
|
||||||
|
|
||||||
fetch_url="${HTTP_VAL}://${_REPO_URL}/${__PY_VERSION_REPO}/redhat/${DISTRO_MAJOR_VERSION}/${CPU_ARCH_L}/${repo_rev}/"
|
fetch_url="${HTTP_VAL}://${_REPO_URL}/${__PY_VERSION_REPO}/redhat/${DISTRO_MAJOR_VERSION}/${CPU_ARCH_L}/${repo_rev}/"
|
||||||
Field_Separator=$IFS
|
for key in $gpg_key; do
|
||||||
IFS=,
|
|
||||||
for key in $gpg_key; do
|
|
||||||
__rpm_import_gpg "${fetch_url}${key}" || return 1
|
__rpm_import_gpg "${fetch_url}${key}" || return 1
|
||||||
done
|
done
|
||||||
IFS=$Field_Separator
|
|
||||||
|
|
||||||
yum clean metadata || return 1
|
yum clean metadata || return 1
|
||||||
elif [ "$repo_rev" != "latest" ]; then
|
elif [ "$repo_rev" != "latest" ]; then
|
||||||
|
|
Loading…
Add table
Reference in a new issue