diff options
author | John <john.mccrae@progress.com> | 2023-01-09 17:28:44 -0800 |
---|---|---|
committer | John <john.mccrae@progress.com> | 2023-01-09 17:28:44 -0800 |
commit | b0d57f8dcfa43293b24227fe8a65d2ad02717552 (patch) | |
tree | 98b1fdb9d86e1e5e43486668630f5ca7e15c4e3c | |
parent | f0a1cdf4f276785bfc3c516cd7b0d40f5cbbdf46 (diff) | |
download | chef-b0d57f8dcfa43293b24227fe8a65d2ad02717552.tar.gz |
Rewriting the zypper code to run only on openSUSE 15
Signed-off-by: John <john.mccrae@progress.com>
-rw-r--r-- | .expeditor/scripts/zypper_prep.sh | 12 | ||||
-rw-r--r-- | .expeditor/verify.pipeline.yml | 12 |
2 files changed, 15 insertions, 9 deletions
diff --git a/.expeditor/scripts/zypper_prep.sh b/.expeditor/scripts/zypper_prep.sh new file mode 100644 index 0000000000..5e87ff0265 --- /dev/null +++ b/.expeditor/scripts/zypper_prep.sh @@ -0,0 +1,12 @@ +#!/bin/bash + +VERSION_STRING=$(cat /etc/os-release | grep '^VERSION=' | sed 's/VERSION=\"\([0-9]\+\).*/\1/') +if [[ $VERSION_STRING == "15" ]] +then + echo "--- :hammer_and_wrench: Updating Zypper Repos on openSUSE 15" + find /etc/zypp/repos.d -name "SMT-*" -execdir rm -f -- '{}' \; + zypper addrepo --check --priority 50 --refresh --name "Chefzypper-repo" "https://mirror.fcix.net/opensuse/distribution/leap/15.3/repo/oss/" "chefzypper" + zypper --gpg-auto-import-keys ref +else + echo "--- :hammer_and_wrench: Not Running on openSUSE 15, nothing to do" +fi diff --git a/.expeditor/verify.pipeline.yml b/.expeditor/verify.pipeline.yml index 5e7467a828..ed321683e8 100644 --- a/.expeditor/verify.pipeline.yml +++ b/.expeditor/verify.pipeline.yml @@ -146,9 +146,7 @@ steps: - label: "Integration openSUSE 15 :ruby: 3.1" commands: - /workdir/.expeditor/scripts/bk_container_prep.sh - - find /etc/zypp/repos.d -name "SMT-*" -execdir rm -f -- '{}' \; - - zypper addrepo --check --priority 50 --refresh --name "Chefzypper-repo" "https://mirror.fcix.net/opensuse/distribution/leap/15.3/repo/oss/" "chefzypper" - - zypper --gpg-auto-import-keys ref + - /workdir/.expeditor/scripts/zypper_prep.sh - zypper install -y cron insserv-compat - cd /workdir; bundle config set --local without omnibus_package - bundle config set --local path 'vendor/bundle' @@ -163,9 +161,7 @@ steps: - label: "Functional openSUSE 15 :ruby: 3.1" commands: - /workdir/.expeditor/scripts/bk_container_prep.sh - - find /etc/zypp/repos.d -name "SMT-*" -execdir rm -f -- '{}' \; - - zypper addrepo --check --priority 50 --refresh --name "Chefzypper-repo" "https://mirror.fcix.net/opensuse/distribution/leap/15.3/repo/oss/" "chefzypper" - - zypper --gpg-auto-import-keys ref + - /workdir/.expeditor/scripts/zypper_prep.sh - zypper install -y cronie insserv-compat - zypper install -y libarchive-devel - cd /workdir; bundle config set --local without omnibus_package @@ -181,9 +177,7 @@ steps: - label: "Unit openSUSE 15 :ruby: 3.1" commands: - /workdir/.expeditor/scripts/bk_container_prep.sh - - find /etc/zypp/repos.d -name "SMT-*" -execdir rm -f -- '{}' \; - - zypper addrepo --check --priority 50 --refresh --name "Chefzypper-repo" "https://mirror.fcix.net/opensuse/distribution/leap/15.3/repo/oss/" "chefzypper" - - zypper --gpg-auto-import-keys ref + - /workdir/.expeditor/scripts/zypper_prep.sh - zypper install -y cron insserv-compat libarchive-devel - bundle config set --local without omnibus_package - bundle config set --local path 'vendor/bundle' |