Commit 6a5bbaa0 authored by Mitchell Hashimoto's avatar Mitchell Hashimoto

Merge pull request #133 from ubermuda/provisioner/shell/script-execution

provisioner/shell: execute script directly instead of using /bin/sh
parents 89e07b87 43db2c23
......@@ -62,7 +62,7 @@ func (p *Provisioner) Prepare(raws ...interface{}) error {
}
if p.config.ExecuteCommand == "" {
p.config.ExecuteCommand = "{{.Vars}} sh {{.Path}}"
p.config.ExecuteCommand = "chmod +x {{.Path}}; {{.Vars}} {{.Path}}"
}
if p.config.Inline != nil && len(p.config.Inline) == 0 {
......
......@@ -51,7 +51,7 @@ Optional parameters:
`key=value`.
* `execute_command` (string) - The command to use to execute the script.
By default this is `{{ .Vars }} sh {{ .Path }}`. The value of this is
By default this is `chmod +x {{ .Path }}; {{ .Vars }} {{ .Path }}`. The value of this is
treated as [configuration template](/docs/templates/configuration-
templates.html). There are two available variables: `Path`, which is
the path to the script to run, and `Vars`, which is the list of
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment