Skip to content

Commit

Permalink
Merge pull request GoogleCloudPlatform#35 from danielezer/master
Browse files Browse the repository at this point in the history
Use the module_enabled flag for all resources
  • Loading branch information
danisla authored Dec 20, 2018
2 parents 9368242 + 6dc9264 commit fd61bad
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ resource "google_compute_firewall" "default-ssh" {
}

resource "google_compute_health_check" "mig-health-check" {
count = "${var.http_health_check ? 1 : 0}"
count = "${var.module_enabled && var.http_health_check ? 1 : 0}"
name = "${var.name}"
project = "${var.project}"

Expand All @@ -260,7 +260,7 @@ resource "google_compute_health_check" "mig-health-check" {
}

resource "google_compute_firewall" "mig-health-check" {
count = "${var.http_health_check ? 1 : 0}"
count = "${var.module_enabled && var.http_health_check ? 1 : 0}"
project = "${var.subnetwork_project == "" ? var.project : var.subnetwork_project}"
name = "${var.name}-vm-hc"
network = "${var.network}"
Expand Down

0 comments on commit fd61bad

Please sign in to comment.