The simplest way to do this (assuming Virtualbox) would be to use the
shared /vagrant/ folder on your guest VMs. If you're using Vagrant boxes
(precise 32) with the host hypervisor tools already installed, when you
boot them up they will automatically map /vagrant/ to the root of your
project folder on your host desktop in the folder where your Vagrantfile
resides.

Any files placed there are automatically available in each VM guest. You
could drop your build into /vagrant/ and each of the other VMs will be able
to read it automatically.

Alternatively, you could use a shell provisioner
<https://www.vagrantup.com/docs/provisioning/shell.html> in each of the
stanzas in your Vagrantfile for your 3 VMs to upload or write out a common
ssh key to each guest so that when you SSH files back and forth between
them, you won't be prompted for a password. You could echo the common
keyfile to /home/vagrant/.ssh/authorized_keys on each guest VM which will
allow them to SSH between each other on the same network. This isn't the
_most_ secure option but assuming you're working locally, you should be ok.

On Tue, Aug 28, 2018 at 8:40 AM <[email protected]> wrote:

> Scenario:
>
> I have setup 3 vagrant boxes. They consist of a web,db, and a build vm.
>
> I am using precise 32 Ubuntu boxes.
>
> The build server starts up last and builds a .war file for my web.
>
> I am trying to transfer file over to web during the machine boot.
>
> I am trying to use scp however it requests a password.
>
>
> Question:
>
> What syntax be it bash, or python can i use to transfer file.  I am trying
> to get around transferring keys to my local host.  I just want to make a
> connection to the web server and copy a file to a directory.
>
> I am looking for the best way.
>
> Thank You for any assistance.
>
>
>
>
>
>
> --
> 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 [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/vagrant-up/e6177889-453b-4cf3-a639-e4e249594b3d%40googlegroups.com
> <https://groups.google.com/d/msgid/vagrant-up/e6177889-453b-4cf3-a639-e4e249594b3d%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>


-- 
JP Toto   |   [email protected]   |   http://jptoto.jp   |   @jptoto
<http://twitter.com/jptoto>

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vagrant-up/CAAYNrX8ini26BmEctmr0%3DYXKrkbhz%3DDk1Vb%3DSHRx%2B25tgOucrw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to