Skip to content

Latest commit

 

History

History
138 lines (110 loc) · 2.68 KB

oci_email_suppressions.md

File metadata and controls

138 lines (110 loc) · 2.68 KB

oci_email_suppressions

back

Index

Terraform

terraform {
  required_providers {
    oci = ">= 4.21.0"
  }
}

top

Example Usage

module "oci_email_suppressions" {
  source = "./modules/oci/d/oci_email_suppressions"

  # compartment_id - (required) is a type of string
  compartment_id = null
  # email_address - (optional) is a type of string
  email_address = null
  # time_created_greater_than_or_equal_to - (optional) is a type of string
  time_created_greater_than_or_equal_to = null
  # time_created_less_than - (optional) is a type of string
  time_created_less_than = null

  filter = [{
    name   = null
    regex  = null
    values = []
  }]
}

top

Variables

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

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

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

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

variable "filter" {
  description = "nested block: NestingSet, min items: 0, max items: 0"
  type = set(object(
    {
      name   = string
      regex  = bool
      values = list(string)
    }
  ))
  default = []
}

top

Datasource

data "oci_email_suppressions" "this" {
  # compartment_id - (required) is a type of string
  compartment_id = var.compartment_id
  # email_address - (optional) is a type of string
  email_address = var.email_address
  # time_created_greater_than_or_equal_to - (optional) is a type of string
  time_created_greater_than_or_equal_to = var.time_created_greater_than_or_equal_to
  # time_created_less_than - (optional) is a type of string
  time_created_less_than = var.time_created_less_than

  dynamic "filter" {
    for_each = var.filter
    content {
      # name - (required) is a type of string
      name = filter.value["name"]
      # regex - (optional) is a type of bool
      regex = filter.value["regex"]
      # values - (required) is a type of list of string
      values = filter.value["values"]
    }
  }

}

top

Outputs

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

output "suppressions" {
  description = "returns a list of object"
  value       = data.oci_email_suppressions.this.suppressions
}

output "this" {
  value = oci_email_suppressions.this
}

top