From edccc2de3f0fa5eb340a264d02710c833efa6374 Mon Sep 17 00:00:00 2001 From: Armon Dadgar Date: Tue, 16 Sep 2014 17:23:01 -0700 Subject: [PATCH] terraform: fixing provisioner invocation --- terraform/context.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/terraform/context.go b/terraform/context.go index 3fd26ce56..73f9b94ed 100644 --- a/terraform/context.go +++ b/terraform/context.go @@ -629,7 +629,7 @@ func (c *Context) applyWalkFn() depgraph.WalkFunc { // Additionally, we need to be careful to not run this if there // was an error during the provider apply. tainted := false - if applyerr == nil && r.State.Primary.ID == "" && len(r.Provisioners) > 0 { + if applyerr == nil && r.State.Primary.ID != "" && len(r.Provisioners) > 0 { for _, h := range c.hooks { handleHook(h.PreProvisionResource(r.Id, r.State)) }