From 7bab499b73a33bbcd358a2e3577b8e9aad7d97b8 Mon Sep 17 00:00:00 2001 From: willmao Date: Sun, 24 Jun 2018 12:23:35 +0800 Subject: [PATCH] fix vpc clean up issue --- builder/alicloud/ecs/step_config_vpc.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/builder/alicloud/ecs/step_config_vpc.go b/builder/alicloud/ecs/step_config_vpc.go index 36d52838f..8ce5663ed 100644 --- a/builder/alicloud/ecs/step_config_vpc.go +++ b/builder/alicloud/ecs/step_config_vpc.go @@ -85,7 +85,8 @@ func (s *stepConfigAlicloudVPC) Cleanup(state multistep.StateBag) { e, _ := err.(*common.Error) if (e.Code == "DependencyViolation.Instance" || e.Code == "DependencyViolation.RouteEntry" || e.Code == "DependencyViolation.VSwitch" || - e.Code == "DependencyViolation.SecurityGroup") && time.Now().Before(timeoutPoint) { + e.Code == "DependencyViolation.SecurityGroup" || + e.Code == "Forbbiden") && time.Now().Before(timeoutPoint) { time.Sleep(1 * time.Second) continue }