back
terraform {
required_providers {
digitalocean = ">= 2.7.0"
}
}
top
module "digitalocean_floating_ip" {
source = "./modules/digitalocean/d/digitalocean_floating_ip"
# ip_address - (required) is a type of string
ip_address = null
}
top
variable "ip_address" {
description = "(required) - floating ip address"
type = string
}
top
data "digitalocean_floating_ip" "this" {
# ip_address - (required) is a type of string
ip_address = var.ip_address
}
top
output "droplet_id" {
description = "returns a number"
value = data.digitalocean_floating_ip.this.droplet_id
}
output "id" {
description = "returns a string"
value = data.digitalocean_floating_ip.this.id
}
output "region" {
description = "returns a string"
value = data.digitalocean_floating_ip.this.region
}
output "urn" {
description = "returns a string"
value = data.digitalocean_floating_ip.this.urn
}
output "this" {
value = digitalocean_floating_ip.this
}
top