Skip to content

Latest commit

 

History

History
237 lines (199 loc) · 5.79 KB

File metadata and controls

237 lines (199 loc) · 5.79 KB

exoscale_ipaddress

back

Index

Terraform

terraform {
  required_providers {
    exoscale = ">= 0.23.0"
  }
}

top

Example Usage

module "exoscale_ipaddress" {
  source = "./modules/exoscale/r/exoscale_ipaddress"

  # description - (optional) is a type of string
  description = null
  # healthcheck_interval - (optional) is a type of number
  healthcheck_interval = null
  # healthcheck_mode - (optional) is a type of string
  healthcheck_mode = null
  # healthcheck_path - (optional) is a type of string
  healthcheck_path = null
  # healthcheck_port - (optional) is a type of number
  healthcheck_port = null
  # healthcheck_strikes_fail - (optional) is a type of number
  healthcheck_strikes_fail = null
  # healthcheck_strikes_ok - (optional) is a type of number
  healthcheck_strikes_ok = null
  # healthcheck_timeout - (optional) is a type of number
  healthcheck_timeout = null
  # healthcheck_tls_skip_verify - (optional) is a type of bool
  healthcheck_tls_skip_verify = null
  # healthcheck_tls_sni - (optional) is a type of string
  healthcheck_tls_sni = null
  # reverse_dns - (optional) is a type of string
  reverse_dns = null
  # tags - (optional) is a type of map of string
  tags = {}
  # zone - (required) is a type of string
  zone = null

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

top

Variables

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

variable "healthcheck_interval" {
  description = "(optional) - Healthcheck probing interval in seconds"
  type        = number
  default     = null
}

variable "healthcheck_mode" {
  description = "(optional) - Healthcheck probing mode"
  type        = string
  default     = null
}

variable "healthcheck_path" {
  description = "(optional) - Healthcheck probe HTTP request path, must be specified in \"http\" mode"
  type        = string
  default     = null
}

variable "healthcheck_port" {
  description = "(optional) - Healthcheck service port to probe"
  type        = number
  default     = null
}

variable "healthcheck_strikes_fail" {
  description = "(optional) - Number of unsuccessful healthcheck probes before considering the target unhealthy"
  type        = number
  default     = null
}

variable "healthcheck_strikes_ok" {
  description = "(optional) - Number of successful healthcheck probes before considering the target healthy"
  type        = number
  default     = null
}

variable "healthcheck_timeout" {
  description = "(optional) - Time in seconds before considering a healthcheck probing failed"
  type        = number
  default     = null
}

variable "healthcheck_tls_skip_verify" {
  description = "(optional) - Healthcheck probe disable TLS verification"
  type        = bool
  default     = null
}

variable "healthcheck_tls_sni" {
  description = "(optional) - Healthcheck probe set server name for TLS SNI"
  type        = string
  default     = null
}

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

variable "tags" {
  description = "(optional) - Map of tags (key: value)"
  type        = map(string)
  default     = null
}

variable "zone" {
  description = "(required) - Name of the zone"
  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 "exoscale_ipaddress" "this" {
  # description - (optional) is a type of string
  description = var.description
  # healthcheck_interval - (optional) is a type of number
  healthcheck_interval = var.healthcheck_interval
  # healthcheck_mode - (optional) is a type of string
  healthcheck_mode = var.healthcheck_mode
  # healthcheck_path - (optional) is a type of string
  healthcheck_path = var.healthcheck_path
  # healthcheck_port - (optional) is a type of number
  healthcheck_port = var.healthcheck_port
  # healthcheck_strikes_fail - (optional) is a type of number
  healthcheck_strikes_fail = var.healthcheck_strikes_fail
  # healthcheck_strikes_ok - (optional) is a type of number
  healthcheck_strikes_ok = var.healthcheck_strikes_ok
  # healthcheck_timeout - (optional) is a type of number
  healthcheck_timeout = var.healthcheck_timeout
  # healthcheck_tls_skip_verify - (optional) is a type of bool
  healthcheck_tls_skip_verify = var.healthcheck_tls_skip_verify
  # healthcheck_tls_sni - (optional) is a type of string
  healthcheck_tls_sni = var.healthcheck_tls_sni
  # reverse_dns - (optional) is a type of string
  reverse_dns = var.reverse_dns
  # tags - (optional) is a type of map of string
  tags = var.tags
  # zone - (required) is a type of string
  zone = var.zone

  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       = exoscale_ipaddress.this.id
}

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

output "tags" {
  description = "returns a map of string"
  value       = exoscale_ipaddress.this.tags
}

output "this" {
  value = exoscale_ipaddress.this
}

top