Commit 4a86f47e authored by Adam Robinson's avatar Adam Robinson
Browse files

fix warnings and errors - latest terraform version

parent edef13a8
......@@ -29,7 +29,7 @@ resource "google_bigquery_dataset" "audit_logs" {
prevent_destroy = true
//Have to ignore access for changes due to circular dependency
ignore_changes = ["access"]
ignore_changes = [access]
}
depends_on = [ google_project_service.bq-api ]
......
......@@ -86,7 +86,7 @@ resource "google_compute_instance_iam_policy" "datalab_user_to_instance_binding"
instance_name = "datalab-${split("@", each.key)[0]}"
project = google_project.hipaa_project[each.value].project_id
zone = var.datalab_zone
policy_data = "${data.google_iam_policy.datalab_user_to_instance_policy[each.key].policy_data}"
policy_data = data.google_iam_policy.datalab_user_to_instance_policy[each.key].policy_data
depends_on = [ null_resource.datalab ]
}
......@@ -106,7 +106,7 @@ resource "null_resource" "datalab" {
}
provisioner "local-exec" {
when = "destroy"
when = destroy
//command = "datalab delete --quiet --delete-disk --project ${google_project.hipaa_project[each.value].project_id} --zone us-central1-a datalab-${split("@", each.key)[0]}"
command = "datalab delete --quiet --delete-disk --project ${self.triggers.project_id} --zone ${var.datalab_zone} datalab-${split("@", self.triggers.user)[0]}"
}
......
......@@ -31,7 +31,7 @@ resource "google_project_iam_binding" "auditor_iam" {
resource "google_project_service" "bq-api" {
for_each = { for v in local.bq_enabled_projects : v => v }
project = google_project.hipaa_project[each.key].project_id
service = "bigquery-json.googleapis.com"
service = "bigquery.googleapis.com"
}
# Prevent Project Deletion for Auditor and Data projects
......
......@@ -28,7 +28,7 @@ variable "dependencies" {
}
variable "datalab_user_list" {
type = "map"
type = map(string)
description = "A map of users to create a datalab instance for. The key is the username and the value is the project id"
default = {}
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment