vagrant-azure icon indicating copy to clipboard operation
vagrant-azure copied to clipboard

warning: already initialized constant VAGRANTFILE_API_VERSION

Open joaquincasares opened this issue 10 years ago • 4 comments

I keep getting these errors every time I run a vagrant command that interacts with an Azure machine:

/$HOME/.vagrant.d/boxes/azure/0/azure/Vagrantfile:5: warning: already initialized constant VAGRANTFILE_API_VERSION
/$HOME/repos/cornerstone/Vagrantfile:1: warning: previous definition of VAGRANTFILE_API_VERSION was here

It seems to come from the following declaration: https://github.com/MSOpenTech/vagrant-azure/blob/master/dummy.box#L8

I tried editing the file locally, but it breaks the binary file. I'm also unsure how I would test this locally.

I did, however, confirm that removing line 5 from .vagrant.d/boxes/azure/0/azure/Vagrantfile allowed my vagrant commands to work as intended.

If you were hoping to force version 2, perhaps add a check instead?

joaquincasares avatar Apr 09 '15 15:04 joaquincasares

Thank you for the nudge. I've been meaning to fix those for a little bit now.

devigned avatar Apr 23 '15 10:04 devigned

I see this too when using vagrant global-status interestingly it only happens when I use the --prune option Perhaps this will help pinpoint things.

jschank avatar Mar 29 '16 22:03 jschank

this is still happening

dsamardzija avatar Jun 15 '16 09:06 dsamardzija

warning: previous definition of VAGRANTFILE_API_VERSION was here Box 'ubuntu1404-opsworks' (v0) with provider 'virtualbox' appears to still be in use by at least one Vagrant environment. Removing the box could corrupt the environment. We recommend destroying these environments first:

default (ID: fb4f1e76016e499880671e0b55464ec6)

Are you sure you want to remove this box? [y/N] y

Even after removing again when trying to run the command "rake virtualbox-install" it still gets the same error. Any quick help will be appreciated!!

Ravikanthbk avatar Sep 12 '16 03:09 Ravikanthbk