From ff550ab1d8f71fd7b349c2167c0aca07f0ffda31 Mon Sep 17 00:00:00 2001 From: Adar Nimrod <nimrod@shore.co.il> Date: Sat, 4 Jan 2025 21:19:22 +0200 Subject: [PATCH] CI: Install opensource software. - Remove the Hashicorp repo. The pre-commit image already has the repos set up correctly and is maintained. - Replace Terraform with OpenTofu. - Install the last opensource version of Packer. --- .gitlab-ci.yml | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 5d80eee..21ce43c 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -9,20 +9,11 @@ pre-commit-try-repo: tags: [ns4.shore.co.il] variables: PIP_CONSTRAINT: /tmp/constraint.txt + TF_CLI: tofu XDG_CACHE_HOME: "$CI_PROJECT_DIR/.cache" before_script: - - >- - curl https://apt.releases.hashicorp.com/gpg | - GNUPGHOME=/tmp gpg --dearmor > - /usr/share/keyrings/hashicorp.gpg - - . /etc/os-release - # yamllint disable rule:line-length - - >- - echo "deb [ signed-by=/usr/share/keyrings/hashicorp.gpg ] https://apt.releases.hashicorp.com $VERSION_CODENAME main" > - /etc/apt/sources.list.d/hashicorp.list - # yamllint enable rule:line-length - apt-get update - - apt-get install -y terraform packer + - apt-get install -y packer=1.9.5-1 tofu # See https://github.com/yaml/pyyaml/issues/736 for the reason for this # workaround. Needed until Ansible doesn't require pyyaml<6. - echo 'Cython < 3.0' > "$PIP_CONSTRAINT" -- GitLab