I'd like to have one Vagrantfile for multiple different OS types (e.g. windows and linux). I'm currently attempting to do something like this:
... if config.vm.guest.to_s == "windows" # ... do something windows specific else # ... do something linux specific end
However, config.vm.guest
returns an Object
instance, not a string or a symbol, even though it was set in the base box Vagrant file (i.e. config.vm.guest = :windows
).
How can I do this?