24 lines
586 B
HCL
24 lines
586 B
HCL
# Buy a new VPS with credit (simulated with a sandbox_ key).
|
|
data "interwebao_catalog_products" "vps" {
|
|
kind = "vps"
|
|
}
|
|
|
|
resource "interwebao_vps" "web" {
|
|
product_id = data.interwebao_catalog_products.vps.products[0].id
|
|
billing_cycle = "monthly"
|
|
power_state = "running"
|
|
timezone = "Africa/Luanda"
|
|
}
|
|
|
|
# Manage a server you already have, without buying anything.
|
|
resource "interwebao_vps" "existing" {
|
|
server_id = 12345
|
|
power_state = "running"
|
|
reverse_dns = {
|
|
"203.0.113.10" = "mail.example.co.ao"
|
|
}
|
|
}
|
|
|
|
output "web_ip" {
|
|
value = interwebao_vps.web.ip
|
|
}
|