Skip to content

Commit

Permalink
Increase subnet & security group deletion timeout (2 -> 5 secs)
Browse files Browse the repository at this point in the history
 - this should prevent DependencyViolation errors while waiting for larger larger ASGs to shut down
  • Loading branch information
radeksimko committed May 9, 2015
1 parent d08ba05 commit 1a28677
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion builtin/providers/aws/resource_aws_security_group.go
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@ func resourceAwsSecurityGroupDelete(d *schema.ResourceData, meta interface{}) er

log.Printf("[DEBUG] Security Group destroy: %v", d.Id())

return resource.Retry(2*time.Minute, func() error {
return resource.Retry(5*time.Minute, func() error {
_, err := conn.DeleteSecurityGroup(&ec2.DeleteSecurityGroupInput{
GroupID: aws.String(d.Id()),
})
Expand Down
2 changes: 1 addition & 1 deletion builtin/providers/aws/resource_aws_subnet.go
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ func resourceAwsSubnetDelete(d *schema.ResourceData, meta interface{}) error {
wait := resource.StateChangeConf{
Pending: []string{"pending"},
Target: "destroyed",
Timeout: 2 * time.Minute,
Timeout: 5 * time.Minute,
MinTimeout: 1 * time.Second,
Refresh: func() (interface{}, string, error) {
_, err := conn.DeleteSubnet(req)
Expand Down

0 comments on commit 1a28677

Please sign in to comment.