vagrant provision a local command

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

vagrant provision a local command

wenlock
Hi, I'm looking for a plugin or method for executing a host command (or bash) during the provision step.  It must be during the provision step because I want to have the ability to do something locally, just before running the next provision script that does something on the guest using the :shell provisioner.

Example:

rsync the local folder ./myscripts/foo.sh to guest location /guest/location

then run my :shell provisioner

/guest/location/myscripts/foo.sh

Any ideas how I can accomplish this?

Thanks,
Edward

--
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/groups/opt_out.
Reply | Threaded
Open this post in threaded view
|

Re: vagrant provision a local command

Emyl
Is the first provisioner different from shell? If so you can put in a script:

vagrant provision --provision-with=[chef|puppet|ansible]
rsync....
vagrant provision --provision-with=shell

Cheers.

On Sunday, August 11, 2013 7:18:50 PM UTC+2, wenlock wrote:
Hi, I'm looking for a plugin or method for executing a host command (or bash) during the provision step.  It must be during the provision step because I want to have the ability to do something locally, just before running the next provision script that does something on the guest using the :shell provisioner.

Example:

rsync the local folder ./myscripts/foo.sh to guest location /guest/location

then run my :shell provisioner

/guest/location/myscripts/foo.sh

Any ideas how I can accomplish this?

Thanks,
Edward

--
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/groups/opt_out.