Hello

By default provisioning scripts only run at creation time.

Next time you do vagrant up/reload the provisioning doesn't run at all.

If there are some provisioning you want to have always to run, you can add


,run: "always"


Does this helps?
Alvaro

On Mon, Nov 13, 2017 at 9:50 PM, Sam Kaplan <stkap...@gmail.com> wrote:

>
> Hi,
>
> In a Vagrantfile, is it possible to detect whether a machine is already
> created? I'm trying to run a block of code only if "vagrant up" is creating
> a new box (and not when re-booting an existing one).
>
> Even a provider-specific method would be helpful -- I'm only using
> Virtualbox.
>
> Thanks,
> Sam
>
> --
> This mailing list is governed under the HashiCorp Community Guidelines -
> https://www.hashicorp.com/community-guidelines.html. Behavior in
> violation of those guidelines may result in your removal from this mailing
> list.
>
> GitHub Issues: https://github.com/mitchellh/vagrant/issues
> IRC: #vagrant on Freenode
> ---
> 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 vagrant-up+unsubscr...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/vagrant-up/c3ef20a6-5ef1-4253-a076-43d381bda8fe%40googlegroups.com
> <https://groups.google.com/d/msgid/vagrant-up/c3ef20a6-5ef1-4253-a076-43d381bda8fe%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Alvaro

-- 
This mailing list is governed under the HashiCorp Community Guidelines - 
https://www.hashicorp.com/community-guidelines.html. Behavior in violation of 
those guidelines may result in your removal from this mailing list.

GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
--- 
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 vagrant-up+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vagrant-up/CAHqq0ex1tghQPwe0SZSKs0OcbvfsbPUD9F3Pv_%2Bz%2B0jozJYEpg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to