Skip to content
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

Change to aws_autoscaling_group removed lifecycle hook #19714

Closed
richardgavel opened this issue Jun 8, 2021 · 3 comments · Fixed by #20708
Closed

Change to aws_autoscaling_group removed lifecycle hook #19714

richardgavel opened this issue Jun 8, 2021 · 3 comments · Fixed by #20708
Labels
bug Addresses a defect in current functionality. service/autoscaling Issues and PRs that pertain to the autoscaling service.
Milestone

Comments

@richardgavel
Copy link

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 other comments that do not add relevant new information or questions, 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

Terraform CLI and Terraform AWS Provider Version

terraform 0.13.6
provider.aws 3.34.0

Affected Resource(s)

  • aws_autoscaling_group

Expected Behavior

The lifecycle hook was added via the initial_lifecycle_hook argument on the aws_autoscaling_group resource.

When updating the auto scaling group (in this case, by updating the launch template by updating instance type, which results in updating the auto scaling group to reference the newer version of the launch template, I expect the lifecycle hook to remain on the auto scaling group. Subsequent runs do not recreate the lifecycle hook.

What is also odd is I'm not sure how the lifecycle hook got added in the first place via an update operation. I see nothing in the code (

func resourceAwsAutoscalingGroupUpdate(d *schema.ResourceData, meta interface{}) error {
) that would suggest it would add the lifecycle hook, only on a create operation.

Actual Behavior

The lifecycle hook no longer exists in AWS console.

  • #0000
@github-actions github-actions bot added needs-triage Waiting for first response or review from a maintainer. service/autoscaling Issues and PRs that pertain to the autoscaling service. labels Jun 8, 2021
@anGie44 anGie44 added bug Addresses a defect in current functionality. and removed needs-triage Waiting for first response or review from a maintainer. labels Jun 8, 2021
@anGie44
Copy link
Contributor

anGie44 commented Jun 8, 2021

Hi @richardgavel , thank you for raising this issue. It seems very closely related to #4714 , as I believe a change in the initial_lifecycle_hook argument should in fact force a new resource instead of an in-place update.

@github-actions
Copy link

This functionality has been released in v4.8.0 of the Terraform AWS Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you!

@github-actions
Copy link

github-actions bot commented May 5, 2022

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 have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 5, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Addresses a defect in current functionality. service/autoscaling Issues and PRs that pertain to the autoscaling service.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants