blob: 11bb240a7b268a0b74a161e72f149a0df3cd5b5b [file] [log] [blame]
---
# devtools tasks/terraform.yml
#
# SPDX-FileCopyrightText: 2022 Open Networking Foundation <support@opennetworking.org>
# SPDX-License-Identifier: Apache-2.0
# terraform
- name: Download terraform archive
get_url:
url: "{{ devtools_terraform_url }}"
checksum: "{{ devtools_terraform_checksum }}"
dest: "/tmp/terraform.zip"
- name: Unarchive terraform
unarchive:
src: "/tmp/terraform.zip"
dest: "/tmp"
remote_src: true
- name: Install terraform binary
copy:
src: /tmp/terraform
dest: /usr/local/bin/terraform
mode: "0755"
remote_src: true
# tfmask
- name: Download/install tfmask binary
get_url:
url: "{{ devtools_tfmask_url }}"
checksum: "{{ devtools_tfmask_checksum }}"
dest: /usr/local/bin/tfmask
mode: "0755"
# cleanup
- name: Cleanup terraform downloads in /tmp
file:
path: "/tmp/{{ item }}"
state: absent
with_items:
- terraform.zip