Skip to content

Commit

Permalink
Update IGM/RIGM tests to use version
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisst authored and modular-magician committed Nov 5, 2019
1 parent 9536005 commit 5aaac30
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 3 deletions.
5 changes: 4 additions & 1 deletion templates/terraform/examples/autoscaler_basic.tf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,10 @@ resource "google_compute_instance_group_manager" "foobar" {
name = "<%= ctx[:vars]['igm_name'] %>"
zone = "us-central1-f"

instance_template = "${google_compute_instance_template.foobar.self_link}"
version {
instance_template = "${google_compute_instance_template.foobar.self_link}"
name = "primary"
}

target_pools = ["${google_compute_target_pool.foobar.self_link}"]
base_instance_name = "foobar"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,12 @@ resource "google_compute_backend_service" "example_backend" {

resource "google_compute_instance_group_manager" "webservers" {
name = "my-webservers"
instance_template = "${google_compute_instance_template.webserver.self_link}"

version {
instance_template = "${google_compute_instance_template.webserver.self_link}"
name = "primary"
}

base_instance_name = "webserver"
zone = "us-central1-f"
target_size = 1
Expand Down
5 changes: 4 additions & 1 deletion templates/terraform/examples/region_autoscaler_basic.tf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,10 @@ resource "google_compute_region_instance_group_manager" "foobar" {
name = "<%= ctx[:vars]['rigm_name'] %>"
region = "us-central1"

instance_template = "${google_compute_instance_template.foobar.self_link}"
version {
instance_template = "${google_compute_instance_template.foobar.self_link}"
name = "primary"
}

target_pools = ["${google_compute_target_pool.foobar.self_link}"]
base_instance_name = "foobar"
Expand Down

0 comments on commit 5aaac30

Please sign in to comment.