From 62690422f5f7b4fae9ab048da124c25a2b569400 Mon Sep 17 00:00:00 2001 From: Marc Beninca Date: Fri, 3 May 2024 13:03:47 +0200 Subject: [PATCH] detect cd_os_version --- cd.sh | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/cd.sh b/cd.sh index 0e50c6a..01a8ca8 100644 --- a/cd.sh +++ b/cd.sh @@ -39,8 +39,14 @@ local variable cd_step "Set environment variables" # case "$(cd_grep_os ID)" in - "debian") CD_OS_ID="${CD_OS_DEBIAN}" ;; - "almalinux") CD_OS_ID="${CD_OS_ALMA}" ;; + "debian") + CD_OS_ID="${CD_OS_DEBIAN}" + CD_OS_VERSION="$(cd_grep_os VERSION_CODENAME)" + ;; + "almalinux") + CD_OS_ID="${CD_OS_ALMA}" + CD_OS_VERSION="$(cd_grep_os VERSION_ID)" + ;; esac # CD_CA_PACKAGE="ca-certificates" @@ -60,7 +66,7 @@ local variable ;; "${CD_OS_ALMA}") case "${CD_OS_VERSION}" in - "8"|"9") cd_nop ;; + "8."*|"9."*) cd_nop ;; *) cd_error_os "CD_OS_VERSION" ;; esac CD_CA_ROOT="/etc/pki/ca-trust/source/anchors"