mirror of
https://github.com/kasmtech/workspaces-images.git
synced 2026-01-23 02:25:16 +00:00
exclude fedora38,39 for terraform installation
This commit is contained in:
parent
062a0bff63
commit
0448d03b19
1 changed files with 7 additions and 1 deletions
|
|
@ -1,17 +1,20 @@
|
|||
#!/usr/bin/env bash
|
||||
set -ex
|
||||
|
||||
ARCH=$(arch | sed 's/aarch64/arm64/g' | sed 's/x86_64/amd64/g')
|
||||
|
||||
if [ "${ARCH}" == "arm64" ] ; then
|
||||
echo "Terraform for arm64 currently not supported, skipping install"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if [[ "${DISTRO}" == @(oracle8|rockylinux9|rockylinux8|oracle9|rhel9|almalinux9|almalinux8) ]]; then
|
||||
dnf config-manager --add-repo https://rpm.releases.hashicorp.com/RHEL/hashicorp.repo
|
||||
dnf install -y terraform
|
||||
if [ -z ${SKIP_CLEAN+x} ]; then
|
||||
dnf clean all
|
||||
fi
|
||||
elif [[ "${DISTRO}" == @(fedora39|fedora40) ]]; then
|
||||
elif [[ "${DISTRO}" == @(fedora40) ]]; then
|
||||
dnf config-manager --add-repo https://rpm.releases.hashicorp.com/fedora/hashicorp.repo
|
||||
# use fedora40 hashicorp packages for terraform
|
||||
sed -i 's/$releasever/40/g' /etc/yum.repos.d/hashicorp.repo
|
||||
|
|
@ -19,6 +22,9 @@ elif [[ "${DISTRO}" == @(fedora39|fedora40) ]]; then
|
|||
if [ -z ${SKIP_CLEAN+x} ]; then
|
||||
dnf clean all
|
||||
fi
|
||||
elif [[ "${DISTRO}" == @(fedora38|fedora39) ]]; then
|
||||
# skip installation for fedora38 and fedora39
|
||||
echo "Skipping terraform install for ${DISTRO}, as it is not officially supported by HashiCorp."
|
||||
else
|
||||
yum-config-manager --add-repo https://rpm.releases.hashicorp.com/RHEL/hashicorp.repo
|
||||
yum install -y terraform
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue