back
terraform {
required_providers {
oci = ">= 4.21.0"
}
}
top
module "oci_identity_auth_token" {
source = "./modules/oci/r/oci_identity_auth_token"
# description - (required) is a type of string
description = null
# user_id - (required) is a type of string
user_id = null
timeouts = [{
create = null
delete = null
update = null
}]
}
top
variable "description" {
description = "(required)"
type = string
}
variable "user_id" {
description = "(required)"
type = string
}
variable "timeouts" {
description = "nested block: NestingSingle, min items: 0, max items: 0"
type = set(object(
{
create = string
delete = string
update = string
}
))
default = []
}
top
resource "oci_identity_auth_token" "this" {
# description - (required) is a type of string
description = var.description
# user_id - (required) is a type of string
user_id = var.user_id
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"]
# update - (optional) is a type of string
update = timeouts.value["update"]
}
}
}
top
output "id" {
description = "returns a string"
value = oci_identity_auth_token.this.id
}
output "inactive_state" {
description = "returns a string"
value = oci_identity_auth_token.this.inactive_state
}
output "state" {
description = "returns a string"
value = oci_identity_auth_token.this.state
}
output "time_created" {
description = "returns a string"
value = oci_identity_auth_token.this.time_created
}
output "time_expires" {
description = "returns a string"
value = oci_identity_auth_token.this.time_expires
}
output "token" {
description = "returns a string"
value = oci_identity_auth_token.this.token
}
output "this" {
value = oci_identity_auth_token.this
}
top