Page MenuHomeSoftware Heritage

Vagrantfile: Avoid extra blocks & shadowing `config` variable
ClosedPublic

Authored by ardumont on Sep 29 2020, 6:05 PM.

Details

Summary

This effectively drops the many Vagrant.configure blocks and keep only the
main one. Then, it renames the main "config" variable into "cfg" and keep the
local variable "config" for each remaining local vm declaration.

Test Plan

vagrant destroy test; vagrant up test is fine

Diff Detail

Repository
rSENV Puppet Environment
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

olasd added a subscriber: olasd.

Rather than cfg, please call the new variable vagrant_config or global_config or anything clearer. I'd rather have a shadowed single variable name than two variable names that can be confused :)

(I'm not sure what's the point of merging the Vagrant.configure blocks but it's not like it hurts anything)

This revision is now accepted and ready to land.Sep 29 2020, 6:09 PM

ack on the naming, it will be clearer indeed.

There is not much point indeed.
Besides avoiding the clash and decrease a bit the declaration.