Skip to content

Commit

Permalink
Fix: Restore usage of var.enable_apis variable for project services s…
Browse files Browse the repository at this point in the history
…ubmodule (#473)
  • Loading branch information
morgante authored Oct 8, 2020
1 parent 04e72d6 commit 05d1465
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion modules/project_services/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/

locals {
services = toset(concat(var.activate_apis, [for i in var.activate_api_identities : i.api]))
services = var.enable_apis ? toset(concat(var.activate_apis, [for i in var.activate_api_identities : i.api])) : toset([])
service_identities = flatten([
for i in var.activate_api_identities : [
for r in i.roles :
Expand Down
2 changes: 1 addition & 1 deletion modules/project_services/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ variable "project_id" {

variable "enable_apis" {
description = "Whether to actually enable the APIs. If false, this module is a no-op."
default = "true"
default = true
}

variable "activate_apis" {
Expand Down

0 comments on commit 05d1465

Please sign in to comment.