Terraform-provider-google: dns zone visibility not written to state in 2.4

Created on 16 Apr 2019  ·  12Comments  ·  Source: hashicorp/terraform-provider-google


Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment
  • If an issue is assigned to the "modular-magician" user, it is either in the process of being autogenerated, or is planned to be autogenerated soon. If an issue is assigned to a user, that user is claiming responsibility for the issue. If an issue is assigned to "hashibot", a community member has claimed the issue already.

Terraform Version

Terraform v0.11.13

  • provider.google v2.4.0

Affected Resource(s)

google_dns_managed_zone

Steps to Reproduce

terraform import

Expected Behavior

state contains visibility="public"

Actual Behavior

state contains visibility=""

Result

visibility: "" => "public" (forces new resource)

Workaround

version = "= 2.3"

bug

Most helpful comment

Hey all! This is a known issue, thanks for your reports. Until we fix this, you can set visibility to "" in order to suppress this diff, which should be the same as setting it to "public". "public" _should_ be the default being returned, but I believe the API suppresses it in the response, returning no value if it would be public.

All 12 comments

Can confirm this bug in version 2.4 of the Google Provider.

This is also affecting us. We will not be able to upgrade from 2.3 until it's addressed.

I'm also stuck on 2.3 due to this.

Same issue here.

Also, while trying to work it around by adding the following:

  visibility = "public"

  private_visibility_config = {
    networks {}
  }

It crashed the provider:

Error: Error running plan: 1 error(s) occurred:

* module.global.module.dns.google_dns_managed_zone.objenio_us: 1 error(s) occurred:

* module.global.module.dns.google_dns_managed_zone.objenio_us: unexpected EOF


panic: interface conversion: interface {} is nil, not map[string]interface {}
2019-04-16T17:51:51.616+0200 [DEBUG] plugin.terraform-provider-google_v2.4.0_x4:
2019-04-16T17:51:51.616+0200 [DEBUG] plugin.terraform-provider-google_v2.4.0_x4: goroutine 386 [running]:
2019-04-16T17:51:51.616+0200 [DEBUG] plugin.terraform-provider-google_v2.4.0_x4: github.com/terraform-providers/terraform-provider-google/google.resourceDn
sManagedZone.func1(0x0, 0x0, 0x1)
2019-04-16T17:51:51.616+0200 [DEBUG] plugin.terraform-provider-google_v2.4.0_x4:        /opt/teamcity-agent/work/5d79fe75d4460a2f/src/github.com/terraform-
providers/terraform-provider-google/google/resource_dns_managed_zone.go:78 +0x321
2019-04-16T17:51:51.616+0200 [DEBUG] plugin.terraform-provider-google_v2.4.0_x4: github.com/terraform-providers/terraform-provider-google/vendor/github.com
/hashicorp/terraform/helper/schema.(*Set).hash(0xc00000bb20, 0x0, 0x0, 0xc000132820, 0xc000132820)
2019-04-16T17:51:51.616+0200 [DEBUG] plugin.terraform-provider-google_v2.4.0_x4:        /opt/teamcity-agent/work/5d79fe75d4460a2f/src/github.com/terraform$
providers/terraform-provider-google/vendor/github.com/hashicorp/terraform/helper/schema/set.go:211 +0x3d
2019-04-16T17:51:51.616+0200 [DEBUG] plugin.terraform-provider-google_v2.4.0_x4: github.com/terraform-providers/terraform-provider-google/vendor/github.com

A work around is to add visibility = "" to the configuration.

Hey all! This is a known issue, thanks for your reports. Until we fix this, you can set visibility to "" in order to suppress this diff, which should be the same as setting it to "public". "public" _should_ be the default being returned, but I believe the API suppresses it in the response, returning no value if it would be public.

Any chance we could get a patch release to fix this and any other minor issues in v2.4.0? The first item in the v2.5.0 changelog has me a little wary that it seems more major than minor. It'd be great to have a small batch of fixes if possible.

Hi @brandoconnor,

That's fair. I think we're currently hoping the 2.5.0 upgrade will be small enough that people will be able to do it, but in the event that people need the patch release and can't do 2.5.0 for whatever reason, I think we want to have a discussion about shipping a 2.4.1 after a 2.5.0. That's not something that has been done before, so I don't want to promise it, but it's possible in theory. Unfortunately, the state of our unreleased changes and the timeline on releasing a 2.5.0 is such that releasing a 2.4.1 is a tough proposition for us right now, but we're monitoring the situation and will change our stance as needed as events develop.

This has been fixed the latest version of the Google Cloud provider v1.5.1.

In addition to 2.5.1, this has also been fixed in version 2.4.1 of the provider, released out of band as a backport in case the 0.12 integration causes issues for users.

Many thanks!

On Tue, Apr 30, 2019, 15:52 Riley Karson notifications@github.com wrote:

In addition to 2.5.1, this has also been fixed in version 2.4.1 of the
provider, released out of band as a backport in case the 0.12 integration
causes issues for users.


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/terraform-providers/terraform-provider-google/issues/3435#issuecomment-488143832,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AATC66HSKADF2M5EY5W4C6TPTDEUNANCNFSM4HGD5QPQ
.

I'm going to lock this issue because it has been closed for _30 days_ ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 [email protected]. Thanks!

Was this page helpful?
0 / 5 - 0 ratings