From: Frank Brehm Date: Wed, 9 Jun 2021 11:44:37 +0000 (+0200) Subject: Fixing postinstall-scripts/init-puppet for CentOS 8 Stream X-Git-Tag: 1.4.12~1 X-Git-Url: https://git.uhu-banane.de/?a=commitdiff_plain;h=f01044b0c6e4bad4f2ae936cbd22c1ae530fdbd6;p=pixelpark%2Fcreate-terraform.git Fixing postinstall-scripts/init-puppet for CentOS 8 Stream --- diff --git a/postinstall-scripts/init-puppet b/postinstall-scripts/init-puppet index 3442d9c..c094304 100755 --- a/postinstall-scripts/init-puppet +++ b/postinstall-scripts/init-puppet @@ -545,11 +545,11 @@ check_os() { info "Checking OS release ..." if [[ -f /etc/redhat-release ]] ; then - if grep --quiet -i "release 8\." /etc/redhat-release ; then + if grep --quiet --extended-regexp --ignore-case "release 8(\.|[ ]*$)" /etc/redhat-release ; then RELEASE=8 - elif grep --quiet -i "release 7\." /etc/redhat-release ; then + elif grep --quiet --ignore-case "release 7\." /etc/redhat-release ; then RELEASE=7 - elif grep --quiet -i "release 6\." /etc/redhat-release ; then + elif grep --quiet --ignore-case "release 6\." /etc/redhat-release ; then RELEASE=6 else error "Found invalid OS release: $(cat /etc/redhat-release)"