This guide will walk you through the steps to install Terraform on Ubuntu / Debian / CentOS / Fedora / Arch Linux system. Terraform is a cloud-agnostic Infrastructure automation tool used to manage cloud and on-premise resources. With it you can build, change, and version infrastructure deployed on popular service providers.

install terraform fedora 29 fedora 28

How to Install Terraform on Linux

Terraform is distributed as a tarball on Github. Check the latest release on Terraform releases page before downloading below.

TER_VER=`curl -s https://api.github.com/repos/hashicorp/terraform/releases/latest | grep tag_name | cut -d: -f2 | tr -d \"\,\v | awk '{$1=$1};1'`
wget https://releases.hashicorp.com/terraform/${TER_VER}/terraform_${TER_VER}_linux_amd64.zip

Once the archive is downloaded, extract and move terraform binary file to the /usr/local/bin directory.

$ unzip terraform_${TER_VER}_linux_amd64.zip
Archive:  terraform_xxx_linux_amd64.zip
 inflating: terraform

$ sudo mv terraform /usr/local/bin/

This will make the tool accessible to all user accounts.

$ which terraform
/usr/local/bin/terraform

Check the version of Terraform installed

$ terraform -v
Terraform v0.14.4

To update Terraform on Linux, download the latest release and use the same process to extract and move binary file to location in your PATH.

Learning video courses:

Also check:

How to Provision VMs on KVM with Terraform

How To Provision VMs on oVirt / RHEV with Terraform

Deploy VM Instances on Hetzner Cloud with Terraform

Build AWS EC2 Machine Images (AMI) With Packer and Ansible

Your support is our everlasting motivation,
that cup of coffee is what keeps us going!


As we continue to grow, we would wish to reach and impact more people who visit and take advantage of the guides we have on our blog. This is a big task for us and we are so far extremely grateful for the kind people who have shown amazing support for our work over the time we have been online.

Thank You for your support as we work to give you the best of guides and articles. Click below to buy us a coffee.

LEAVE A REPLY

Please enter your comment!
Please enter your name here