Step-by-step tutorial of how to download and install Terraform on Windows, Linux and Mac OS.

Terraform is distributed as a binary package for all supported platforms and architectures and must first be installed on your machine.

Check out the releases CHANGELOG for more information on the latest release and choose the version that is required for your Operating System and your project. If you just getting started with Terraform , I suggest you to get the latest release.

Download Terraform

You can  download a version of Terraform from the releases service.

Install Terraform – Windows

  1. Download terraform for windows

    • Note: Terraform is packaged as a zip archive, so after downloading Terraform, unzip the package. Terraform runs as a single binary named terraform. Any other files in the package can be safely removed and Terraform will still function
  2. Copy files from the zip to “c:\terraform” for example. That’s our terraform PATH.
  3. The final step is to make sure that the terraform binary is available on the PATH.

General Information

  • The PATH is the system variable that your operating system uses to locate needed executables from the command line or Terminal window.
  • The PATH system variable can be set using System Utility in control panel on Windows, or in your shell’s startup file on Linux.

Windows 10 and Windows 8

  1. In Search, search for and then select: System (Control Panel)
  2. Click the System and Security link.
  3. Click the System link.
  4. Click the Advanced system settings link.
  5. Click Environment Variables. In the section System Variables, find the PATH environment variable and select it. Click Edit. If the PATH environment variable does not exist, click New.
  6. In the Edit System Variable (or New System Variable) window, append at the end of the PATH environment variable the value of terraform path ex.”c:\terraform;” . Click OK. Close all remaining windows by clicking OK.
  7. Reopen Command prompt window, and run terraform.

Windows 7

  1. From the desktop, right click the Computer icon.
  2. Choose Properties from the context menu.
  3. Click the Advanced system settings link.
  4. Click Environment Variables. In the section System Variables, find the PATH environment variable and select it. Click Edit. If the PATH environment variable does not exist, click New.
  5. In the Edit System Variable (or New System Variable) window, append at the end of the PATH environment variable the value of terraform path ex.”c:\terraform;” . Click OK. Close all remaining windows by clicking OK.
  6. Reopen Command prompt window, and run terraform.

Windows XP

  1. Select Start, select Control Panel. double click System, and select the Advanced tab.
  2. Click Environment Variables. In the section System Variables, find the PATH environment variable and select it. Click Edit. If the PATH environment variable does not exist, click New.
  3. In the Edit System Variable (or New System Variable) window, append at the end of the PATH environment variable the value of terraform path ex.”c:\terraform;” . Click OK. Close all remaining windows by clicking OK.
  4. Reopen Command prompt window, and run terraform.

Install Terraform – Linux

  1. Download terraform for linux

     
    1
    $ wget https://releases.hashicorp.com/terraform/0.xx.x/terraform_0.xx.x_linux_amd64.zip
    • Note: Terraform is packaged as a zip archive, so after downloading Terraform, unzip the package. Terraform runs as a single binary named terraform. Any other files in the package can be safely removed and Terraform will still function
  2. Install unzip
     
    1
    $ sudo apt-get install unzip
  3. Unzip and set path.
     
    1
    2
    $ unzip terraform_0.11.1_linux_amd64.zip
    $ sudo mv terraform /usr/local/bin/

Install Terraform – Mac OS

The easiest and quickest way to install Terraform is using Homebrew.

 
1
$ brew install terraform

Or Manually if the latest version is not ideal for your needs.

  1. Download terraform for macos

    • Note: Terraform is packaged as a zip archive, so after downloading Terraform, unzip the package. Terraform runs as a single binary named terraform. Any other files in the package can be safely removed and Terraform will still function
  2. Extract files from the zip to “$HOME/Downloads/terraform” for example.
  3. The final step is to make sure that the terraform binary is available on the PATH.
  4. Copy binary to a place in the path such as /usr/local/bin/terraform
 
1
$ cp $HOME/Downloads/terraform /usr/local/bin/

Verify Install

When you’re done, you should be able to run the terraform command and get the usage information:

 
 
 
 
 

Arduino

 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
$ terraform
Usage: terraform [--version] [--help] <command> [args]
 
The available commands for execution are listed below.
The most common, useful commands are shown first, followed by
less common or more advanced commands. If you're just getting
started with Terraform, stick with the common commands. For the
other commands, please read the help and docs before usage.
 
Common commands:
    apply              Builds or changes infrastructure
    console            Interactive console for Terraform interpolations
    destroy            Destroy Terraform-managed infrastructure
    env                Workspace management
    fmt                Rewrites config files to canonical format
    get                Download and install modules for the configuration
    graph              Create a visual graph of Terraform resources
    import             Import existing infrastructure into Terraform
    init               Initialize a Terraform working directory
    output             Read an output from a state file
    plan               Generate and show an execution plan
    providers          Prints a tree of the providers used in the configuration
    push               Upload this Terraform module to Atlas to run
    refresh            Update local state file against real resources
    show               Inspect Terraform state or plan
    taint              Manually mark a resource for recreation
    untaint            Manually unmark a resource as tainted
    validate           Validates the Terraform files
    version            Prints the Terraform version
    workspace          Workspace management
 
All other commands:
    debug              Debug output management (experimental)
    force-unlock       Manually unlock the terraform state
    state              Advanced state management

Link: https://www.vasos-koupparis.com/terraform-getting-started-install/

Install Terraform on Windows, Linux and Mac OS的更多相关文章

  1. 从Windows角度看Mac OS X上的软件开发

    如果原来从事Windows软件开发,想跨足或转换至Mac OS X环境,需要知道那些东西?有什么知识技能可以快速运用在Mac OS X环境上的?这两个问题应该是Windows开发者进入Mac OS X ...

  2. 常用Linux/Unix/Mac Os命令

    常用Linux/Unix/Mac OS命令 参考: 1.50 Most Frequently Used UNIX / Linux Commands (With Examples)

  3. Sqlite在Windows、Linux 和 Mac OS X 上的安装过程

    一:在 Windows 上安装 SQLite 1,下载 请访问SQLite下载页面http://www.sqlite.org/download.html,从Windows 区下载预编译的二进制文件.需 ...

  4. [Sqlite] --&gt; Sqlite于Windows、Linux 和 Mac OS X 在安装过程

    一个:于 Windows 安装 SQLite  1,下载 请訪问SQLite下载页面http://www.sqlite.org/download.html.从Windows 区下载预编译的二进制文件. ...

  5. [C] zintrin.h : 智能引入intrinsic函数。支持VC、GCC,兼容Windows、Linux、Mac OS X

    博客来源:http://blog.csdn.net/zyl910/article/details/8100744 现在很多编译器支持intrinsic函数,这给编写SSE等SIMD代码带来了方便.但是 ...

  6. Java 反编译工具 —— JAD 的下载地址(Windows版/Linux版/Mac OS 版)

    Java 反编译工具 —— JAD 的下载地址. 各种版本哦! Windows版,Linux版,Mac OS 版,等等 下载地址: http://varaneckas.com/jad/

  7. remote desktop connect btw Mac, Windows, Linux(Ubuntu) Mac,Windows,Linux之间的远程桌面连接

    目录 I. 预备 II. Mac连接Windows III. Windows连接Mac IV. Windows连接Ubuntu V. Mac连接Ubuntu VI. Ubuntu连接Mac VII, ...

  8. 桂电在linux、Mac OS环境下使用出校器(支持2.14)

    这是guetsec学长在三院科协学长所抓包逆向分析1.81版出校器的基础上,用python写的一款为Mac和linux环境开发的出校器. 最后我做了略微修改,支持暂时最新版本2.14.下面有直接从源码 ...

  9. 在windows下制作mac os x的启动安装U盘

    前几天有幸用了下Macbook pro,可在给它装win 7系统时,无知而又手贱地在windows系统下分区了:( 然后再重启就找不到Mac os x,只有win 7了.可进win 7也不正常,直接给 ...

随机推荐

  1. 亚马逊:PS4和Xbox One实在太火

    圣诞节刚刚结束,当实体零售商在抱怨坑爹的天气让自己节日生意变得冷清的同时,在线零售商们却依旧赚的盆满钵满. 亚马逊近日表示,今年节日期间的零售工作非常不错,新一代游戏机更是最大的亮点.据销售统计,在圣 ...

  2. sqoop导入数据到hive表中的相关操作

    1.使用sqoop创建表并且指定对应的hive表中的字段的数据类型,同时指定该表的分区字段名称 sqoop create-hive-table --connect "jdbc:oracle: ...

  3. react native组件的创建

    react native组件的创建 react文件加载顺序: react项目启动后,先加载index.js.在index.js中可以指向首页. import { AppRegistry } from ...

  4. Alpha发布—文案+美工展示

    目录 团队简介 项目进展 组内分工 队员总结 后期计划 一.团队简介 二.项目进展 从选题发布到今天的Alpha发布,我们团队经历了许许多多的磨难.我们最终设计了如下的功能:首页.班级.个人.更多.打 ...

  5. C# string 常用方法

    string.ToString().Contains() String str="abcd" str.ToString().Contains("a"); //t ...

  6. postion一句话很管用

    relative和absolute有本质区别,relative是相对与postion为默认值的时候元素自身位置来定位:而absolute是相对最近position为relative或absolute的 ...

  7. Codeforces Round #345 (Div. 1) C. Table Compression dp+并查集

    题目链接: http://codeforces.com/problemset/problem/650/C C. Table Compression time limit per test4 secon ...

  8. 读 《我是一只IT小小鸟》 有感

    在没有上大学之前,我很迷茫自己将来要从事什么行业.有人说,人生的每一个阶段都应该有自己的目标,然而,我上大学之前,甚至大一下学期之前,我对于我今后的从业道路,人生规划,都是迷茫的.高考结束成绩出来后, ...

  9. css全局样式基础代码

    body{ font-size:12px; font-family:"宋体",Arial, Helvetica, sans-serif;color:#363636;backgrou ...

  10. Swift-setValuesForKeysWithDictionary

    重写 setValuesForKeysWithDictionary 那么字典中可以有的字段在类中没有对应属性 class Person : NSObject { var age :Int = // 重 ...