Created
January 29, 2016 15:15
-
-
Save emaildano/f4112b5f40d5ca3452ba to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
hostname, *aliases = wordpress_sites.flat_map { |(_name, site)| site['site_hosts'] } | |
config.vm.hostname = hostname | |
www_aliases = ["www.#{hostname}"] + aliases.map { |host| "www.#{host}" } | |
if Vagrant.has_plugin? 'vagrant-hostsupdater' | |
config.hostsupdater.aliases = aliases + www_aliases | |
else | |
fail_with_message "vagrant-hostsupdater missing, please install the plugin with this command:\nvagrant plugin install vagrant-hostsupdater" | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment