Skip to content

Latest commit

 

History

History
161 lines (131 loc) · 2.99 KB

azurerm_iothub_route.md

File metadata and controls

161 lines (131 loc) · 2.99 KB

azurerm_iothub_route

back

Index

Terraform

terraform {
  required_providers {
    azurerm = ">= 2.54.0"
  }
}

top

Example Usage

module "azurerm_iothub_route" {
  source = null

  # condition - (optional) is a type of string
  condition = null
  # enabled - (required) is a type of bool
  enabled = null
  # endpoint_names - (required) is a type of list of string
  endpoint_names = []
  # iothub_name - (required) is a type of string
  iothub_name = null
  # name - (required) is a type of string
  name = null
  # resource_group_name - (required) is a type of string
  resource_group_name = null
  # source - (required) is a type of string

  timeouts = [{
    create = null
    delete = null
    read   = null
    update = null
  }]
}

top

Variables

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

variable "enabled" {
  description = "(required)"
  type        = bool
}

variable "endpoint_names" {
  description = "(required)"
  type        = list(string)
}

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

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

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

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

variable "timeouts" {
  description = "nested block: NestingSingle, min items: 0, max items: 0"
  type = set(object(
    {
      create = string
      delete = string
      read   = string
      update = string
    }
  ))
  default = []
}

top

Resource

resource "azurerm_iothub_route" "this" {
  # condition - (optional) is a type of string
  condition = var.condition
  # enabled - (required) is a type of bool
  enabled = var.enabled
  # endpoint_names - (required) is a type of list of string
  endpoint_names = var.endpoint_names
  # iothub_name - (required) is a type of string
  iothub_name = var.iothub_name
  # name - (required) is a type of string
  name = var.name
  # resource_group_name - (required) is a type of string
  resource_group_name = var.resource_group_name
  # source - (required) is a type of string
  source = var.source

  dynamic "timeouts" {
    for_each = var.timeouts
    content {
      # create - (optional) is a type of string
      create = timeouts.value["create"]
      # delete - (optional) is a type of string
      delete = timeouts.value["delete"]
      # read - (optional) is a type of string
      read = timeouts.value["read"]
      # update - (optional) is a type of string
      update = timeouts.value["update"]
    }
  }

}

top

Outputs

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

output "this" {
  value = azurerm_iothub_route.this
}

top