From 9beac8d286d2e06ed90781a58a11472c69ee275d Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Thu, 1 May 2014 14:13:22 -0700 Subject: [PATCH] provisioner/chef-client: proper ordering of args [GH-1100] --- provisioner/chef-client/provisioner.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/provisioner/chef-client/provisioner.go b/provisioner/chef-client/provisioner.go index 451019498..1e2847f54 100644 --- a/provisioner/chef-client/provisioner.go +++ b/provisioner/chef-client/provisioner.go @@ -342,7 +342,7 @@ func (p *Provisioner) createDir(ui packer.Ui, comm packer.Communicator, dir stri func (p *Provisioner) cleanNode(ui packer.Ui, comm packer.Communicator, node string) error { ui.Say("Cleaning up chef node...") - app := "knife node delete -y " + node + app := fmt.Sprintf("knife node delete %s -y", node) cmd := exec.Command("sh", "-c", app) out, err := cmd.Output() @@ -358,7 +358,7 @@ func (p *Provisioner) cleanNode(ui packer.Ui, comm packer.Communicator, node str func (p *Provisioner) cleanClient(ui packer.Ui, comm packer.Communicator, node string) error { ui.Say("Cleaning up chef client...") - app := "knife client delete -y " + node + app := fmt.Sprintf("knife client delete %s -y", node) cmd := exec.Command("sh", "-c", app) out, err := cmd.Output()