From dbaf8d14a9cdfcef0281919671357f6171ebd4e6 Mon Sep 17 00:00:00 2001 From: anniehedgpeth Date: Wed, 3 May 2017 13:17:55 -0500 Subject: [PATCH] updating Hashicorp's changes to merged simple linux branch --- examples/azure-vm-simple-linux-managed-disk/README.md | 8 ++------ .../azure-vm-simple-linux-managed-disk/deploy.mac.sh | 2 +- examples/azure-vm-simple-linux-managed-disk/main.tf | 11 +++++++++-- .../azure-vm-simple-linux-managed-disk/outputs.tf | 4 ++-- .../azure-vm-simple-linux-managed-disk/provider.tf | 7 ------- .../terraform.tfvars | 8 -------- 6 files changed, 14 insertions(+), 26 deletions(-) delete mode 100644 examples/azure-vm-simple-linux-managed-disk/provider.tf delete mode 100644 examples/azure-vm-simple-linux-managed-disk/terraform.tfvars diff --git a/examples/azure-vm-simple-linux-managed-disk/README.md b/examples/azure-vm-simple-linux-managed-disk/README.md index 0492e3edccb9..cde5c458e82d 100644 --- a/examples/azure-vm-simple-linux-managed-disk/README.md +++ b/examples/azure-vm-simple-linux-managed-disk/README.md @@ -1,10 +1,6 @@ # Very simple deployment of a Linux VM - - - - -This template allows you to deploy a simple Linux VM using a few different options for the Ubuntu version, using the latest patched version. This will deploy a A1 size VM in the resource group location and return the FQDN of the VM. +This template allows you to deploy a simple Linux VM using a few different options for the Ubuntu version, using the latest patched version. This will deploy an A0 size VM in the resource group location and return the FQDN of the VM. This template takes a minimum amount of parameters and deploys a Linux VM, using the latest patched version. @@ -21,4 +17,4 @@ Azure requires that an application is added to Azure Active Directory to generat If a `terraform.tfvars` file is present in the current directory, Terraform automatically loads it to populate variables. We don't recommend saving usernames and password to version control, but you can create a local secret variables file and use `-var-file` to load it. ## variables.tf -The `variables.tf` file contains all of the input parameters that the user can specify when deploying this Terraform template. +The `variables.tf` file contains all of the input parameters that the user can specify when deploying this Terraform template. \ No newline at end of file diff --git a/examples/azure-vm-simple-linux-managed-disk/deploy.mac.sh b/examples/azure-vm-simple-linux-managed-disk/deploy.mac.sh index 9c6563f07d71..dfc34c2be2fc 100755 --- a/examples/azure-vm-simple-linux-managed-disk/deploy.mac.sh +++ b/examples/azure-vm-simple-linux-managed-disk/deploy.mac.sh @@ -12,4 +12,4 @@ if docker -v; then else echo "Docker is used to run terraform commands, please install before run: https://docs.docker.com/docker-for-mac/install/" -fi +fi \ No newline at end of file diff --git a/examples/azure-vm-simple-linux-managed-disk/main.tf b/examples/azure-vm-simple-linux-managed-disk/main.tf index 8ef283c7819c..5dc9ce1cb086 100644 --- a/examples/azure-vm-simple-linux-managed-disk/main.tf +++ b/examples/azure-vm-simple-linux-managed-disk/main.tf @@ -1,3 +1,10 @@ +# provider "azurerm" { +# subscription_id = "REPLACE-WITH-YOUR-SUBSCRIPTION-ID" +# client_id = "REPLACE-WITH-YOUR-CLIENT-ID" +# client_secret = "REPLACE-WITH-YOUR-CLIENT-SECRET" +# tenant_id = "REPLACE-WITH-YOUR-TENANT-ID" +# } + resource "azurerm_resource_group" "rg" { name = "${var.resource_group}" location = "${var.location}" @@ -34,7 +41,7 @@ resource "azurerm_public_ip" "pip" { name = "${var.rg_prefix}-ip" location = "${var.location}" resource_group_name = "${azurerm_resource_group.rg.name}" - public_ip_address_allocation = "dynamic" + public_ip_address_allocation = "Dynamic" domain_name_label = "${var.dns_name}" } @@ -95,7 +102,7 @@ resource "azurerm_virtual_machine" "vm" { } boot_diagnostics { - enabled = "true" + enabled = true storage_uri = "${azurerm_storage_account.stor.primary_blob_endpoint}" } } \ No newline at end of file diff --git a/examples/azure-vm-simple-linux-managed-disk/outputs.tf b/examples/azure-vm-simple-linux-managed-disk/outputs.tf index 9e3c2f0712bc..32c6294ceeab 100644 --- a/examples/azure-vm-simple-linux-managed-disk/outputs.tf +++ b/examples/azure-vm-simple-linux-managed-disk/outputs.tf @@ -6,6 +6,6 @@ output "vm_fqdn" { value = "${azurerm_public_ip.pip.fqdn}" } -output "sshCommand" { +output "ssh_command" { value = "ssh ${var.admin_username}@${azurerm_public_ip.pip.fqdn}" -} +} \ No newline at end of file diff --git a/examples/azure-vm-simple-linux-managed-disk/provider.tf b/examples/azure-vm-simple-linux-managed-disk/provider.tf deleted file mode 100644 index 79291f7ca895..000000000000 --- a/examples/azure-vm-simple-linux-managed-disk/provider.tf +++ /dev/null @@ -1,7 +0,0 @@ -# provider "azurerm" { -# subscription_id = "REPLACE-WITH-YOUR-SUBSCRIPTION-ID" -# client_id = "REPLACE-WITH-YOUR-CLIENT-ID" -# client_secret = "REPLACE-WITH-YOUR-CLIENT-SECRET" -# tenant_id = "REPLACE-WITH-YOUR-TENANT-ID" -# } - diff --git a/examples/azure-vm-simple-linux-managed-disk/terraform.tfvars b/examples/azure-vm-simple-linux-managed-disk/terraform.tfvars deleted file mode 100644 index bee98e4e11bc..000000000000 --- a/examples/azure-vm-simple-linux-managed-disk/terraform.tfvars +++ /dev/null @@ -1,8 +0,0 @@ -# Replace with relevant values - -# resource_group = "myresourcegroup" -# rg_prefix = "rg" -# hostname = "myvm" -# dns_name = "mydnsname" -# location = "southcentralus" -# admin_password = "T3rr@f0rmP@ssword"