Add Rocky Linux to nodepool elements tooling

Change-Id: I2a94a34b1518c90ef5f0d91c9131482520c38c62
This commit is contained in:
Neil Hanlon 2022-02-15 16:01:53 -05:00
parent e14c59a6e1
commit cc6b6de7a0
No known key found for this signature in database
GPG Key ID: 705BC21EC3C70F34
6 changed files with 16 additions and 9 deletions

View File

@ -20,8 +20,8 @@ if [ ${DIB_DEBUG_TRACE:-0} -gt 0 ]; then
fi fi
set -e set -e
if [[ "$DISTRO_NAME" == centos && ${DIB_RELEASE} != '9-stream' ]] ; then if [[ "$DISTRO_NAME" =~ ^(centos|rocky)$ && ${DIB_RELEASE} != '9-stream' ]] ; then
# 9-stream we are just using the default rngd # 9-stream we are just using the default rngd
# Note: $YUM exposed by centos environment, correct across releases # Note: $YUM exposed by centos|rhel-like environment, correct across releases
${YUM} -y install --enablerepo=epel haveged ${YUM} -y install --enablerepo=epel haveged
fi fi

View File

@ -13,6 +13,13 @@
"iptables": "iptables-services" "iptables": "iptables-services"
} }
}, },
"rocky": {
"8": {
"python-dev": "",
"ntp": "chrony",
"ntpdate": ""
}
},
"ubuntu": { "ubuntu": {
"focal": { "focal": {
"ntp": "", "ntp": "",

View File

@ -17,7 +17,7 @@ case "$DIB_INIT_SYSTEM" in
if [[ ${DIB_RELEASE} != 'focal' ]]; then if [[ ${DIB_RELEASE} != 'focal' ]]; then
systemctl enable ntp.service systemctl enable ntp.service
fi fi
elif [[ ( $DISTRO_NAME == "centos" && $DIB_RELEASE > 7 ) || $DISTRO_NAME == "fedora" ]]; then elif [[ ( $DISTRO_NAME == "centos" && $DIB_RELEASE > 7 ) || $DISTRO_NAME == "fedora" || $DISTRO_NAME == "rocky" ]]; then
systemctl enable chronyd systemctl enable chronyd
else else
systemctl enable ntpd.service systemctl enable ntpd.service

View File

@ -68,7 +68,7 @@ mv /tmp/forwarding.conf /etc/unbound/
chown root:root /etc/unbound/forwarding.conf chown root:root /etc/unbound/forwarding.conf
chmod a+r /etc/unbound/forwarding.conf chmod a+r /etc/unbound/forwarding.conf
if [[ "$DISTRO_NAME" =~ (centos|rhel7|fedora|openeuler) ]] ; then if [[ "$DISTRO_NAME" =~ (centos|rhel7|fedora|openeuler|rocky) ]] ; then
LOG_FILE="/var/lib/unbound/unbound.log" LOG_FILE="/var/lib/unbound/unbound.log"
else else
LOG_FILE="/var/log/unbound.log" LOG_FILE="/var/log/unbound.log"
@ -82,7 +82,7 @@ server:
verbosity: 5" verbosity: 5"
echo "$UNBOUND_LOGGING_CONF" > /tmp/unbound-logging.conf echo "$UNBOUND_LOGGING_CONF" > /tmp/unbound-logging.conf
if [[ "$DISTRO_NAME" =~ (centos|rhel7|fedora|opensuse|openeuler) ]] ; then if [[ "$DISTRO_NAME" =~ (centos|rhel7|fedora|opensuse|openeuler|rocky) ]] ; then
UNBOUND_CONFD=/etc/unbound/conf.d UNBOUND_CONFD=/etc/unbound/conf.d
elif [[ "$DISTRO_NAME" =~ 'gentoo' ]] ; then elif [[ "$DISTRO_NAME" =~ 'gentoo' ]] ; then
UNBOUND_CONFD=/etc/unbound/conf.d UNBOUND_CONFD=/etc/unbound/conf.d
@ -185,7 +185,7 @@ sed -i -e 's/dlv-anchor-file:/#dlv-anchor-file:/g' /etc/unbound/unbound.conf
# Tripleo uses dhcp # Tripleo uses dhcp
dhcp_file='' dhcp_file=''
if [[ "$DISTRO_NAME" =~ (centos|rhel7|fedora|openeuler) ]] ; then if [[ "$DISTRO_NAME" =~ (centos|rhel7|fedora|openeuler|rocky) ]] ; then
dhcp_file=/etc/dhcp/dhclient-eth0.conf dhcp_file=/etc/dhcp/dhclient-eth0.conf
elif [[ "$DISTRO_NAME" =~ (debian|ubuntu|gentoo) ]] ; then elif [[ "$DISTRO_NAME" =~ (debian|ubuntu|gentoo) ]] ; then
dhcp_file=/etc/dhcp/dhclient.conf dhcp_file=/etc/dhcp/dhclient.conf

View File

@ -24,7 +24,7 @@ if [[ "$DISTRO_NAME" =~ (debian|ubuntu) ]] ; then
rules_dir=/etc/iptables rules_dir=/etc/iptables
ipv4_rules=${rules_dir}/rules.v4 ipv4_rules=${rules_dir}/rules.v4
ipv6_rules=${rules_dir}/rules.v6 ipv6_rules=${rules_dir}/rules.v6
elif [[ "$DISTRO_NAME" =~ (centos|rhel7|fedora|openeuler) ]] ; then elif [[ "$DISTRO_NAME" =~ (centos|rhel7|fedora|openeuler|rocky) ]] ; then
rules_dir=/etc/sysconfig rules_dir=/etc/sysconfig
ipv4_rules=${rules_dir}/iptables ipv4_rules=${rules_dir}/iptables
ipv6_rules=${rules_dir}/ip6tables ipv6_rules=${rules_dir}/ip6tables

View File

@ -22,7 +22,7 @@ set -e
if [[ "$DISTRO_NAME" =~ (debian|ubuntu) ]] ; then if [[ "$DISTRO_NAME" =~ (debian|ubuntu) ]] ; then
service_name=netfilter-persistent service_name=netfilter-persistent
elif [[ "$DISTRO_NAME" =~ (centos|rhel7|fedora|openeuler) ]] ; then elif [[ "$DISTRO_NAME" =~ (centos|rhel7|fedora|openeuler|rocky) ]] ; then
service_name=iptables service_name=iptables
elif [[ "$DISTRO_NAME" == 'opensuse' ]] ; then elif [[ "$DISTRO_NAME" == 'opensuse' ]] ; then
# handle iptables through init.d instead of a service # handle iptables through init.d instead of a service
@ -48,7 +48,7 @@ case "$DIB_INIT_SYSTEM" in
else else
systemctl enable ${service_name}.service systemctl enable ${service_name}.service
fi fi
if [[ "$DISTRO_NAME" =~ (centos|rhel7|fedora|openeuler) ]] ; then if [[ "$DISTRO_NAME" =~ (centos|rhel7|fedora|openeuler|rocky) ]] ; then
systemctl enable ip6tables.service systemctl enable ip6tables.service
fi fi
;; ;;