Skip to content

Conversation

@modular-magician
Copy link
Collaborator

Fixes #25457

According to the REST API, if not specified, it defaults to "AUTOMATIC".
While GoogleCloudPlatform/magic-modules#15808 fixes the case where the entire scaling block is missing and causing permadiff, it doesn't handle a case where the block only contains "min_instance_count = 0".

What happens is, if min_instance_count = 0 is the only field specified, the response from the API has the scaling = [] and so it's saved as in the terraform state file.

Release Note Template for Downstream PRs (will be copied)

See Write release notes for guidance.

cloudrunv2: fixed a permadiff when default values of the `scaling` block were explicitly declared on the `google_cloud_run_v2_service` resource

Derived from GoogleCloudPlatform/magic-modules#15904

…n resource `google_cloud_run_v2_service` (hashicorp#15904)

[upstream:05d749828aebd97521e0560ad3382bdd673ddacf]

Signed-off-by: Modular Magician <[email protected]>
@modular-magician modular-magician merged commit 9e0afb2 into hashicorp:main Dec 15, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Setting min_instance_count = 0 causes google_cloud_run_v2_service to show diffs on every plan even after a successful apply

1 participant