-
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
"Unset" value for google_compute_region_instance_group_manager target_size argument? #667
Comments
Taking a look at what the cloud console claims a REST request for MIG with autoscaling is, I think the "unset" value is actually 1. Can you give that a try @danisla and see if that works? And now it makes sense to me why 1 was originally the default here. I think the right answer for the future is to get rid of the |
@danawillow, I set the
I get an error if I try to apply it:
I have a hack workaround now, which forces the target_size = "${var.autoscaling ? var.min_replicas : var.size}" |
Ah ok, that makes sense, and now I see why this was so tricky. We want @apparentlymart you might be interested in this since I know you're working on improvements in this area. |
I haven't actually checked, but this might be fixable now either with GetOkExists or CustomDiff. I'm not working on it right now though so unassigning. |
This should be resolved by the upcoming 0.12 changes. |
Signed-off-by: Modular Magician <magic-modules@google.com>
This should be possible in |
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 👉 hashibot-feedback@hashicorp.com. Thanks! |
Related issues: #65, #13. Terraform #5471
Affected resources:
The
target_size
argument is mutually exclusive from the autoscaler resource. Is there a way to conditionally set thetarget_size
argument so that when I'm using a autoscaler, it can be unset?Setting it to
0
forces my instance group to0
, which conflicts with the autoscaler.If
0
was the unset value, then the above indented use case would work. If0
is valid, can we use-1
?The text was updated successfully, but these errors were encountered: