Add example of reading the file

This commit is contained in:
Seth Vargo 2014-11-14 15:55:14 -05:00
parent fb53f6f3f2
commit aa60fe6031
1 changed files with 9 additions and 0 deletions

View File

@ -39,6 +39,15 @@ config.push.define "local-exec" do |push|
end
```
For more complicated scripts, you may store them in a separate file and read
them from the `Vagrantfile` like so:
```ruby
config.push.define "local-exec" do |push|
push.command = File.read("my-script.sh")
end
```
And then invoke the push with Vagrant:
```shell