Increase subnet & security group deletion timeout (2 -> 5 mins)

- this should prevent DependencyViolation errors while waiting for larger ASGs to shut down
This commit is contained in:
Radek Simko 2015-05-09 21:52:56 +01:00
parent d08ba05d2c
commit 754bcd8307
2 changed files with 2 additions and 2 deletions

View File

@ -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()),
})

View File

@ -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)