Enabling/Disabling plugins

12 views
Skip to first unread message

Michael

unread,
Mar 8, 2018, 7:59:23 AM3/8/18
to Vagrant
Hi all,

I'm looking at creating a Vagrant VM using a CI server with no internet connection. Or rather, the CI only has a connection to the internet via Artifactory, which is acting as a proxy for Yum packages and Vagrant boxes, including caching those files for reproducibility.

I'm trying to build a VM with centos/7 (v1801.02, Virtualbox) as a base image. I would also like to install VirtualBox Guest Additions, using the Vagrant plugin vagrant-vbguest. 

I will include a sanitised Vagrantfile and build script as attachments for this process.


What I am trying to do is the following:
 - Disable vagrant-vbguest
 - Provision the VM
 - Enable vagrant-vbguest
 - Vagrant up again (to install Guest Additions)
 - Export the VM

However, it seems that after provisioning the machine with the plugin disabled, re-enabling the plugin has no effect. How can I cause the above set of steps to occur?

Michael
Vagrantfile
build.sh

Alvaro Miranda Aguilera

unread,
Mar 8, 2018, 8:25:40 AM3/8/18
to vagra...@googlegroups.com
hello

it seems packer is a better tool for this, you can use virtualbox-ovf to start from an existing box

have a look here:

however, if you really want to use vagrant, you can use a shell provisioner to do the virtualbox part, so you keep all under control

the vbox guest is an iso, you can mount it as part of the script and do the install





--
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+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/06daea1a-c111-48e0-87ab-205cf0f28bbe%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Alvaro

Reply all
Reply to author
Forward
0 new messages