tfwriter

Terraform HCL code generator.

Download as .zip Download as .tar.gz View on GitHub

avi_alertsyslogconfig

back

Index

Terraform

terraform {
  required_providers {
    avi = ">= 0.2.3"
  }
}

top

Example Usage

module "avi_alertsyslogconfig" {
  source = "./modules/avi/r/avi_alertsyslogconfig"

  # description - (optional) is a type of string
  description = null
  # name - (required) is a type of string
  name = null
  # tenant_ref - (optional) is a type of string
  tenant_ref = null
  # uuid - (optional) is a type of string
  uuid = null

  syslog_servers = [{
    anon_auth                   = null
    format                      = null
    pkiprofile_ref              = null
    ssl_key_and_certificate_ref = null
    syslog_server               = null
    syslog_server_port          = null
    tls_enable                  = null
    udp                         = null
  }]
}

top

Variables

variable "description" {
  description = "(optional)"
  type        = string
  default     = null
}

variable "name" {
  description = "(required)"
  type        = string
}

variable "tenant_ref" {
  description = "(optional)"
  type        = string
  default     = null
}

variable "uuid" {
  description = "(optional)"
  type        = string
  default     = null
}

variable "syslog_servers" {
  description = "nested block: NestingList, min items: 0, max items: 0"
  type = set(object(
    {
      anon_auth                   = bool
      format                      = string
      pkiprofile_ref              = string
      ssl_key_and_certificate_ref = string
      syslog_server               = string
      syslog_server_port          = number
      tls_enable                  = bool
      udp                         = bool
    }
  ))
  default = []
}

top

Resource

resource "avi_alertsyslogconfig" "this" {
  # description - (optional) is a type of string
  description = var.description
  # name - (required) is a type of string
  name = var.name
  # tenant_ref - (optional) is a type of string
  tenant_ref = var.tenant_ref
  # uuid - (optional) is a type of string
  uuid = var.uuid

  dynamic "syslog_servers" {
    for_each = var.syslog_servers
    content {
      # anon_auth - (optional) is a type of bool
      anon_auth = syslog_servers.value["anon_auth"]
      # format - (optional) is a type of string
      format = syslog_servers.value["format"]
      # pkiprofile_ref - (optional) is a type of string
      pkiprofile_ref = syslog_servers.value["pkiprofile_ref"]
      # ssl_key_and_certificate_ref - (optional) is a type of string
      ssl_key_and_certificate_ref = syslog_servers.value["ssl_key_and_certificate_ref"]
      # syslog_server - (required) is a type of string
      syslog_server = syslog_servers.value["syslog_server"]
      # syslog_server_port - (optional) is a type of number
      syslog_server_port = syslog_servers.value["syslog_server_port"]
      # tls_enable - (optional) is a type of bool
      tls_enable = syslog_servers.value["tls_enable"]
      # udp - (required) is a type of bool
      udp = syslog_servers.value["udp"]
    }
  }

}

top

Outputs

output "description" {
  description = "returns a string"
  value       = avi_alertsyslogconfig.this.description
}

output "id" {
  description = "returns a string"
  value       = avi_alertsyslogconfig.this.id
}

output "tenant_ref" {
  description = "returns a string"
  value       = avi_alertsyslogconfig.this.tenant_ref
}

output "uuid" {
  description = "returns a string"
  value       = avi_alertsyslogconfig.this.uuid
}

output "this" {
  value = avi_alertsyslogconfig.this
}

top