-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bad deprecation on google_container_cluster.binary_authorization.enabled
#16759
Bad deprecation on google_container_cluster.binary_authorization.enabled
#16759
Comments
I don't think this is right, if the user passes both an evaluation mode and enabled bool the evaluation mode has precedence. |
In the API, or Terraform specifically? I think that Terraform is always sending an explicit value to the API. |
Request/response:
That does mean that an explicit false is not a problem. Note that
|
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. |
Community Note
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 tohashibot
, a community member has claimed the issue already.Terraform Version
Affected Resource(s)
Terraform Configuration Files
Debug Output
Panic Output
Expected Behavior
Binary authorization remains enabled
Actual Behavior
Binary authorization is disabled
Steps to Reproduce
terraform apply
Important Factoids
In
5.0.0
we deprecatedenable_binary_authorization
in favour ofbinary_authorization.enabled
: https://registry.terraform.io/providers/hashicorp/google/latest/docs/guides/version_5_upgrade#enable_binary_authorization-is-now-removedHowever, the field that we directed folks to was introduced as deprecated in GoogleCloudPlatform/magic-modules#6101 and pointed folks to a different field,
binary_authorization.evaluation_mode
. In the API if you send just that field the API will determineenabled
based on its value (and has deprecated setting enablement explicitly). Our implementation always sends an enabled field, which appears to override the value.This means that I don't think that that upgrade path is possible- and a user that attempts to resolve the deprecation warning is likely to accidentally set
binary_authorization.enabled
tofalse
, disabling binary authorization on their cluster regardless of theirevaluation_mode
setting.We should update our
5.0.0
upgrade guide to warn against specifying justevaluation_mode
, and either remove the deprecation clientside until we handle it properly or fix our handling.References
b/315582550
The text was updated successfully, but these errors were encountered: