Skip to content

Commit ee3865b

Browse files
authored
feat(budget): Only read project data when budget will be created (#829)
1 parent de1c1a1 commit ee3865b

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

examples/gke_shared_vpc/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,6 @@ More information about GKE with Shared VPC can be found here: https://cloud.goog
3636

3737
## Outputs
3838

39-
No output.
39+
No outputs.
4040

4141
<!-- END OF PRE-COMMIT-TERRAFORM DOCS HOOK -->

modules/budget/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ locals {
3434

3535
data "google_project" "project" {
3636
depends_on = [var.projects]
37-
count = length(var.projects)
37+
count = var.create_budget ? length(var.projects) : 0
3838
project_id = element(var.projects, count.index)
3939
}
4040

0 commit comments

Comments
 (0)