Create an EC2 Instance with Terraform

From NovaOrdis Knowledge Base
Revision as of 21:35, 13 November 2019 by Ovidiu (talk | contribs) (→‎Internal)
Jump to navigation Jump to search

External

Internal

Overview

EC2 instances can be created, updated and deleted. Instances also support provisioning.

Configuration

provider "aws" {

  profile = "default"
  region = "us-west-2"
}

resource "aws_instance" "terraform-test-01" {

  ami           = "ami-a6faba49dddaecfb7"
  instance_type = "m5.4xlarge"
}

Configuration Details

Public IP

If nothing is specified, the instance will get a public IP.