Installing Terraform 0.9.11 on Ubuntu 17.04


  • Service Provider

    Terraform is extremely simple to install, but because it does not use an installer might look scary at first. But just follow these steps for an extremely simple install.

    First, we need to download Terraform 0.9.11 for Linux AMD64. This is a very fast download. It comes as a zip file.

    If you have a GUI on your machine, you can likely just right click on the zip file and "extract here". If you are doing this at the command line, just change your directory into your download location and use the unzip command on the file that was just downloaded.

    The download contains only one file. Once extracted, you should see a file simply named terraform. This is the binary of the application and it is all that is needed. Terraform is very simple in this way.

    Now as root we just need to move this binary to an appropriate location. I like /usr/local/bin/ so we can do this:

    sudo mv terraform /usr/local/bin/
    

    Once we do that, we can do this to test that all is well:

    cd ~
    terraform --version
    

    If Terraform runs, we are successful.



  • So it is like 2 seconds to install... what is it?


  • Service Provider

    @travisdh1 said in Installing Terraform 0.9.11 on Ubuntu 17.04:

    So it is like 2 seconds to install... what is it?

    Platform automation tool.



  • How does this compare to Salt?



  • @fuznutz04 said in Installing Terraform 0.9.11 on Ubuntu 17.04:

    How does this compare to Salt?

    Salt is a CM/Automation tool, this is an infrstructure provisioning tool. You can use things like Salt and Ansible for infrastructure but this is faster and purpose built for that.



  • You can do some CM in terraform also. You can do remote exec after it finishes like this:

    provisioner "file" {
           source = "file.config"
           destination = "/etc/configs/file.confg"
    }
    

    'You can ouput info for Ansible (or others) from Terraform after it finishes. For example:

    provisioner "local-exec" {
          command = "echo ${aws_instance.example.public_dns} >> inventory"
    }
    ouput "name" {
          value = "${aws_instance.example.public_dns}"
    }


Looks like your connection to MangoLassi was lost, please wait while we try to reconnect.