MagaluCloud / terraform-provider-mgc

Magalu Cloud terraform provider
https://docs.magalu.cloud/docs/terraform/overview
8 stars 1 forks source link

[BUG] - Resource `mgc_network_public_ips` is bogus #48

Closed nawarian closed 3 weeks ago

nawarian commented 2 months ago

Describe the bug

The registry's docs have the mgc_network_public_ips resource listed, but it doesn't really exist.

A quick check on tofu's fetched schema shows that the resource is not available.

tofu providers schema -json | jq .

This is rather important because without this resource I can't attach a public_ip to my vpc.

To Reproduce

// network.tf
resource "mgc_network_vpc" "codamos_vpc" {
  name = "codamos-vpc"
}

resource "mgc_network_public_ips" "codamos_public_ip" {
  vpc_id = mgc_network_vpc.codamos_vpc.id
}
$ tf apply
╷
│ Error: Invalid resource type
│ 
│   on network.tf line 5, in resource "mgc_network_public_ips" "codamos_public_ip":
│    5: resource "mgc_network_public_ips" "codamos_public_ip" {
│ 
│ The provider registry.terraform.io/magalucloud/mgc does not support resource type "mgc_network_public_ips".
╵

Expected behavior

Resources should be available as described by the docs.

Desktop:

nawarian commented 2 months ago

Moving forward with my tests I've also found that most things related to networking are documented but not yet available, although their respective mgc CLI commands seem to work fine.

I see resourecs like mgc_network_public_ips, mgc_network_rules or mgc_network_security_groups are documented but the terraform schema doesn't offer these resources.

This got me very confused and frustrated. But I appreciate this is still in its early stages, so I'll just do some workarounds via CLI and keep moving forward.

publi0 commented 3 weeks ago

Solved on the latest release v0.29.2