2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2025-05-22 03:32:04 +00:00

Add workaround for sles-15 in go-xcat

This commit is contained in:
Samveen 2023-05-19 10:20:32 +05:30
parent de3976ac37
commit 3c0e09a116
No known key found for this signature in database
GPG Key ID: 5B17F3D06B420F2D

View File

@ -1741,6 +1741,15 @@ function github_issue_5503_workaround()
return 0
}
# Workaround for SLES 15 deprecating old initscript commands
function github_issue_6525_workaround()
{
[[ "${GO_XCAT_LINUX_DISTRO}" = "sles" ]] || return 0
[[ "${GO_XCAT_LINUX_VERSION}" =~ ^15 ]] || return 0
zypper install net-tools-deprecated insserv-compat
return 0
}
# Check for EPEL and CRB repositories when installing on RH family of OSes
function el9_epel_and_crb_check()
{
@ -1794,6 +1803,7 @@ function install_packages_zypper()
{
type zypper >/dev/null 2>&1 || return 255
github_issue_5503_workaround
github_issue_6525_workaround
local -a yes=()
[[ "$1" = "-y" ]] && yes=("-n") && shift
zypper --no-gpg-checks "${yes[@]}" install --force-resolution "$@"