adb-atomic-developer-bundle icon indicating copy to clipboard operation
adb-atomic-developer-bundle copied to clipboard

warnings during "vagrant destroy -f <id>

Open optak opened this issue 8 years ago • 4 comments

vagrant destroy -f <id> generates several warning messages, but destroying box from current dirrectory has no problem. This is reproducible by both Vagrantfiles for (cdk rhel-k8s-singlenode-setup, rhel-ose), but not for freshly created one:

vagrant init
vagrant up
vagrant destroy -f 468bc69

Output of vagrant destroy -f <id>:

  • rhel-ose
/home/cdk/cdk/components/rhel/rhel-ose3/Vagrantfile:5: warning: already initialized constant PUBLIC_ADDRESS
/home/cdk/cdk/components/rhel/rhel-ose3/Vagrantfile:5: warning: previous definition of PUBLIC_ADDRESS was here
/home/cdk/cdk/components/rhel/rhel-ose3/Vagrantfile:8: warning: already initialized constant VM_CPU
/home/cdk/cdk/components/rhel/rhel-ose3/Vagrantfile:8: warning: previous definition of VM_CPU was here
/home/cdk/cdk/components/rhel/rhel-ose3/Vagrantfile:11: warning: already initialized constant VM_MEMORY
/home/cdk/cdk/components/rhel/rhel-ose3/Vagrantfile:11: warning: previous definition of VM_MEMORY was here
/home/cdk/cdk/components/rhel/rhel-ose3/Vagrantfile:14: warning: already initialized constant REQUIRED_PLUGINS
/home/cdk/cdk/components/rhel/rhel-ose3/Vagrantfile:14: warning: previous definition of REQUIRED_PLUGINS was here
  • rhel-k8s-singlenode-setup
/home/cdk/cdk/components/rhel/misc/rhel-k8s-singlenode-setup/Vagrantfile:3: warning: already initialized constant REQUIRED_PLUGINS
/home/cdk/cdk/components/rhel/misc/rhel-k8s-singlenode-setup/Vagrantfile:3: warning: previous definition of REQUIRED_PLUGINS was here

optak avatar Apr 18 '16 11:04 optak

@budhrg : Is this because of ruby constants defined in Vagrantfile? https://github.com/projectatomic/adb-atomic-developer-bundle/blob/master/components/rhel/rhel-ose/Vagrantfile#L5-L25

navidshaikh avatar Apr 18 '16 11:04 navidshaikh

Yes, it's because vagrant defines that variables, but I didn't noticed that warnings in past, and we had at least PUBLIC_ADDRESS, so it's probably something newl Interesting is, that destroy without specific box ID prints no warnings. I expect these two ways of destroying box to almost identical. Note that this is only "cosmetic" issue, I can't see anything broken by this, it just looks ugly.

optak avatar Apr 18 '16 12:04 optak

Interesting is, that destroy without specific box ID prints no warnings. I expect these two ways of destroying box to almost identical.

Agree on that, I'd also expect them to be identical.

Note that this is only "cosmetic" issue, I can't see anything broken by this, it just looks ugly.

It does, we should fix this for completeness.

navidshaikh avatar Apr 18 '16 12:04 navidshaikh

This seems to be related to Vagrant life cycle, mostly how Vagrant perform operation on vagrant destroy. Digging on it.

brgnepal avatar Apr 18 '16 15:04 brgnepal