using inline commands in vagrantfile won't work

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

using inline commands in vagrantfile won't work

John McAfee
I am using Vagrant and VirtualBox on the MacBook for the first time.
Setup was simple and I was up and running with a simple.
However, when attempting to automate creating a virtual machine with a few provisions, I get errors.
Most specific, using any command to try and interact with a file in my "/vagrant" synced folder is not working.
It doesn't matter ... cp, mv, tar ... no command works on any file using the command from the Vagrantfile.
It says either it can't find it or it can not open it.  I have used every sudo and chmod 777 command I know
to rule out any permission issue.

However, if I ssh into the vagrant box, the commands works just fine ... just as I have them in the Vagrantfile.
Can someone please tell me what I am doing wrong in the Vagrantfile?


Please find attached my Vagrantfile and a debug log (vagrant.log) 

Thank you,


John

--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/4f07495b-47d1-4aa7-bbf8-527f70811d22%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Vagrantfile (1K) Download Attachment
vagrant.log (325K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: using inline commands in vagrantfile won't work

Alvaro Miranda Aguilera
Hello

In the documentation there is an example on how to do multi line inline scripts.


For the shared folder in virtualbox to work, the guest need to have virtualbox additions and kernel modules installed.

I would suggest test a different box first, ie hashicorp/precise64

and then check the documentation for virtualbox to make sure all is fine.

Alvaro.

On Fri, Jun 23, 2017 at 8:07 PM, John McAfee <[hidden email]> wrote:
I am using Vagrant and VirtualBox on the MacBook for the first time.
Setup was simple and I was up and running with a simple.
However, when attempting to automate creating a virtual machine with a few provisions, I get errors.
Most specific, using any command to try and interact with a file in my "/vagrant" synced folder is not working.
It doesn't matter ... cp, mv, tar ... no command works on any file using the command from the Vagrantfile.
It says either it can't find it or it can not open it.  I have used every sudo and chmod 777 command I know
to rule out any permission issue.

However, if I ssh into the vagrant box, the commands works just fine ... just as I have them in the Vagrantfile.
Can someone please tell me what I am doing wrong in the Vagrantfile?


Please find attached my Vagrantfile and a debug log (vagrant.log) 

Thank you,


John

--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/4f07495b-47d1-4aa7-bbf8-527f70811d22%40googlegroups.com.
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0exSVjjqHLbuw897FGhdSfxWMn7LXXjNbxv_ZMve0tBLUg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.