Skip to content

Commit

Permalink
Fix Terraform autoscaler tests disk image (#416)
Browse files Browse the repository at this point in the history
Merged PR #416.
  • Loading branch information
rileykarson authored and modular-magician committed Aug 27, 2018
1 parent f96c83d commit 0da0832
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 4 deletions.
2 changes: 1 addition & 1 deletion build/terraform
Original file line number Diff line number Diff line change
Expand Up @@ -221,14 +221,19 @@ func testAccCheckComputeAutoscalerUpdated(n string, max int64) resource.TestChec

func testAccComputeAutoscaler_scaffolding(it_name, tp_name, igm_name string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
family = "debian-9"
project = "debian-cloud"
}
resource "google_compute_instance_template" "foobar" {
name = "%s"
machine_type = "n1-standard-1"
can_ip_forward = false
tags = ["foo", "bar"]
disk {
source_image = "debian-cloud/debian-8-jessie-v20160803"
source_image = "${data.google_compute_image.my_image.self_link}"
auto_delete = true
boot = true
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,14 +152,19 @@ func testAccCheckComputeRegionAutoscalerUpdated(n string, max int64) resource.Te

func testAccComputeRegionAutoscaler_basic(it_name, tp_name, igm_name, autoscaler_name string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
family = "debian-9"
project = "debian-cloud"
}
resource "google_compute_instance_template" "foobar" {
name = "%s"
machine_type = "n1-standard-1"
can_ip_forward = false
tags = ["foo", "bar"]
disk {
source_image = "debian-cloud/debian-8-jessie-v20160803"
source_image = "${data.google_compute_image.my_image.self_link}"
auto_delete = true
boot = true
}
Expand Down Expand Up @@ -212,14 +217,19 @@ resource "google_compute_region_autoscaler" "foobar" {

func testAccComputeRegionAutoscaler_update(it_name, tp_name, igm_name, autoscaler_name string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
family = "debian-9"
project = "debian-cloud"
}
resource "google_compute_instance_template" "foobar" {
name = "%s"
machine_type = "n1-standard-1"
can_ip_forward = false
tags = ["foo", "bar"]
disk {
source_image = "debian-cloud/debian-8-jessie-v20160803"
source_image = "${data.google_compute_image.my_image.self_link}"
auto_delete = true
boot = true
}
Expand Down

0 comments on commit 0da0832

Please sign in to comment.