OpenNebula / terraform-provider-opennebula

Terraform provider for OpenNebula
https://www.terraform.io/docs/providers/opennebula/
Mozilla Public License 2.0
65 stars 52 forks source link

opennebula_template and opennebula_image datasources not working anymore after upgrade provider ppgrade #370

Closed ps-beilers closed 1 year ago

ps-beilers commented 1 year ago

Community Note

Terraform Version

Terraform v1.3.4
+ provider registry.terraform.io/opennebula/opennebula v1.0.1

Affected Resource(s)

Terraform Configuration Files

data "opennebula_template" "generic_ubuntu_terraform" {
  name = "Generic Ubuntu Terraform"
}
data "opennebula_image" "bionic" {
  name = "bionic_2022-11"
}

Debug Output

(https://gist.github.com/ps-beilers/a7cda9f3af56351acb4446b8334c5867)

Panic Output

Expected Behavior

The datasources should have returned the template and image objects.

Actual Behavior

No objects were found. The plan or apply commands fail with Error: (images|templates) filtering failed

Steps to Reproduce

We upgraded our community OpenNebula installation from 5.6 to 6.2. Afterwards we upgraded the terraform provider from 0.4.0 to 1.0.1. We also tried with 0.5.2 which showed the same issues as 1.0.1.

  1. terraform apply

Important Factoids

References

treywelsh commented 1 year ago

I reproduced the problem for the template datasource, we already discussed around this problem (in #349 around hasXXX flags handling).

However for the image datasource I didn't reproduced, is it related to #331 (could you check @ps-beilers ) ? If yes, we're waiting for a PR to update the goca dependency which fix some default behavior. If not, I'll need to test in depth.

ps-beilers commented 1 year ago

I reproduced the problem for the template datasource, we already discussed around this problem (in #349 around hasXXX flags handling).

However for the image datasource I didn't reproduced, is it related to #331 (could you check @ps-beilers ) ? If yes, we're waiting for a PR to update the goca dependency which fix some default behavior. If not, I'll need to test in depth.

Hi @treywelsh

Most likely it is related to #331, yes. Looking forward to the fix from #371 making it into the next tag.

Regards, Bernd