feat: install opentofu and check network access
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed

This commit is contained in:
Aravinth Manivannan 2023-12-11 14:58:21 +05:30
parent b6b58b6156
commit 64302fed4c
Signed by: realaravinth
GPG key ID: F8F50389936984FF

View file

@ -2,10 +2,17 @@ steps:
backend:
image: python:3-bookworm
commands:
- whoami
- apt-get update
- apt upgrade -y
- apt-get install -y ca-certificates curl gnupg tar wget libssl-dev python3-pip cython3 pipx
- apt-get install -y ca-certificates curl gnupg tar wget libssl-dev python3-pip cython3 pipx apt-transport-https coreutils iputils-ping
- install -m 0755 -d /etc/apt/keyrings
- curl -fsSL https://packages.opentofu.org/opentofu/tofu/gpgkey | gpg --no-tty --batch --dearmor -o /etc/apt/keyrings/opentofu.gpg
- chmod a+r /etc/apt/keyrings/opentofu.gpg
- echo "deb [signed-by=/etc/apt/keyrings/opentofu.gpg] https://packages.opentofu.org/opentofu/tofu/any/ any main" > /etc/apt/sources.list.d/opentofu.list
echo "deb-src [signed-by=/etc/apt/keyrings/opentofu.gpg] https://packages.opentofu.org/opentofu/tofu/any/ any main" >> /etc/apt/sources.list.d/opentofu.list
- apt-get update
- apt-get install -y tofu
- ping -c 10 192.168.0.102
- ping -c 10 192.168.0.127
- pipx install --include-deps ansible
- pipx ensurepath && echo $SHELL
- /root/.local/bin/ansible-galaxy install -r ./ansible/requirements.yml