given this terraform variable definition: variable "disks" { description = "Storage…
- User
given this terraform variable definition: variable "disks" { description = "Storage configuration for each group of machines" type = list(object({ machines = list(string) name = string size_gigabytes = number model = string partitions = list(object({ size_gigabytes = number fs_type = optional(string) mount_point = optional(string) })) })) }
And this variable value: disks = {[ machines = ["node02"] name = "sda" size_gigabytes = 120 model = "KINGSTON SV300S3" partitions = [ { size_gigabytes = 1 fs_type = "fat32" mount_point = "/boot/efi" }, { size_gigabytes = 90 fs_type = "ext4" mount_point = "/" },, { size_gigabytes = 15 fs_type = "ext4" mount_point = "/home" }, ] ], [ machines = ["node02"] name = "sdb" size_gigabytes = 120 model = "KINGSTON SM2280S" partitions = [ { size_gigabytes = 20 fs_type = "ext4" mount_point = "/media" }] ]}
Create the terraform resource block to create a maas_block_device resource for each disk of each machine. e.g. machine called node02 should have 2 disks i.e. sda and sdb.
Assistant
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.