In my previous article, we discussed what is terraform and why we need terraform. Today, we discuss the steps to install Terraform.
1. Go to Install | Terraform | HashiCorp Developer and select the Windows tab. Download the AMD64 zip file.
2. Go to C: drive and create a Terraform folder. Unzip the file downloaded in the previous step and copy the terraform.exe file to the C:\Terraform folder.
3. Open File Explorer, right-click on “This PC” and select Properties.
4. Go to Advanced settings
5. Select Environment variables.
6. Add Terraform path C:\Terraform\ to either User Variables or System Variables “Path” variables. Select the “Path” variable and click on Edit. Once you open the Edit environment variable screen, add the terraform path C:\Terraform\ and click the OK button for all screens.
7. Restart your PC
8. To validate the Terraform installation, open Visual Studio Code, which we will use for Terraform development and execute the “Terraform --Version" command to check the Terraform version. If you don’t have Microsoft Visual Studio Code, download it from Download Visual Studio Code - Mac, Linux, Windows and install.