From: Frank Brehm Date: Mon, 12 Oct 2020 11:01:24 +0000 (+0200) Subject: Modification for EL 8 X-Git-Tag: 1.4.8~1^2 X-Git-Url: https://git.uhu-banane.org/?a=commitdiff_plain;h=46eeb1db13f8d65658fab8c42724378c0824f84c;p=pixelpark%2Fcreate-terraform.git Modification for EL 8 --- diff --git a/postinstall-scripts/init-puppet b/postinstall-scripts/init-puppet index 1e7dddb..63de5c8 100755 --- a/postinstall-scripts/init-puppet +++ b/postinstall-scripts/init-puppet @@ -21,7 +21,7 @@ NORMAL="" HAS_TTY='y' HAS_COLORS="n" -VERSION="1.0" +VERSION="1.1" BASENAME="$(basename ${0})" BASE_DIR="$(dirname ${0})" @@ -367,7 +367,7 @@ get_options() { debug "Using following options:" if [[ "${VERBOSE}" == "y" ]] ; then - cat <<-EOF + local msg=$( cat <<-EOF FQDN: ${GREEN}${FQDN}${NORMAL} Puppet environment: ${GREEN}${ENVIRONMENT}${NORMAL} Tier: ${GREEN}${TIER}${NORMAL} @@ -378,6 +378,8 @@ get_options() { Purpose: ${GREEN}${PURPOSE}${NORMAL} EOF + ) + echo -e "${msg}" fi } @@ -512,9 +514,11 @@ check_os() { info "Checking OS release ..." if [[ -f /etc/redhat-release ]] ; then - if grep --quiet -i "release 7" /etc/redhat-release ; then + if grep --quiet -i "release 8\." /etc/redhat-release ; then + RELEASE=8 + elif grep --quiet -i "release 7\." /etc/redhat-release ; then RELEASE=7 - elif grep --quiet -i "release 6" /etc/redhat-release ; then + elif grep --quiet -i "release 6\." /etc/redhat-release ; then RELEASE=6 else error "Found invalid OS release: $(cat /etc/redhat-release)"