back
terraform {
required_providers {
fortios = ">= 1.11.0"
}
}
top
module "fortios_user_devicegroup" {
source = "./modules/fortios/r/fortios_user_devicegroup"
# comment - (optional) is a type of string
comment = null
# dynamic_sort_subtable - (optional) is a type of string
dynamic_sort_subtable = null
# name - (required) is a type of string
name = null
member = [{
name = null
}]
tagging = [{
category = null
name = null
tags = [{
name = null
}]
}]
}
top
variable "comment" {
description = "(optional)"
type = string
default = null
}
variable "dynamic_sort_subtable" {
description = "(optional)"
type = string
default = null
}
variable "name" {
description = "(required)"
type = string
}
variable "member" {
description = "nested block: NestingList, min items: 0, max items: 0"
type = set(object(
{
name = string
}
))
default = []
}
variable "tagging" {
description = "nested block: NestingList, min items: 0, max items: 0"
type = set(object(
{
category = string
name = string
tags = list(object(
{
name = string
}
))
}
))
default = []
}
top
resource "fortios_user_devicegroup" "this" {
# comment - (optional) is a type of string
comment = var.comment
# dynamic_sort_subtable - (optional) is a type of string
dynamic_sort_subtable = var.dynamic_sort_subtable
# name - (required) is a type of string
name = var.name
dynamic "member" {
for_each = var.member
content {
# name - (optional) is a type of string
name = member.value["name"]
}
}
dynamic "tagging" {
for_each = var.tagging
content {
# category - (optional) is a type of string
category = tagging.value["category"]
# name - (optional) is a type of string
name = tagging.value["name"]
dynamic "tags" {
for_each = tagging.value.tags
content {
# name - (optional) is a type of string
name = tags.value["name"]
}
}
}
}
}
top
output "id" {
description = "returns a string"
value = fortios_user_devicegroup.this.id
}
output "this" {
value = fortios_user_devicegroup.this
}
top