Skip to content

Commit

Permalink
Merge pull request #14 from remerge/DATA-40-scratch-disk-support
Browse files Browse the repository at this point in the history
Support scratch disks for google/compute
  • Loading branch information
hollow authored Sep 6, 2023
2 parents e0818ae + 0b43d4d commit 5dfa789
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
7 changes: 7 additions & 0 deletions google/compute/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,13 @@ resource "google_compute_instance_from_template" "main" {
}
}

dynamic "scratch_disk" {
for_each = range(var.scratch_disk_count)
content {
interface = "NVME"
}
}

# checkov:skip=CKV_GCP_32:False positive, keys are blocked
}

Expand Down
5 changes: 5 additions & 0 deletions google/compute/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -79,3 +79,8 @@ variable "interface" {
type = string
default = null
}

variable "scratch_disk_count" {
type = number
default = 0
}

0 comments on commit 5dfa789

Please sign in to comment.