tnargav 1.2.3 → 1.3.3
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +19 -3
- data/CHANGELOG.md +311 -0
- data/bin/vagrant +12 -0
- data/config/default.rb +2 -4
- data/keys/README.md +0 -7
- data/lib/vagrant.rb +7 -0
- data/lib/vagrant/action.rb +2 -0
- data/lib/vagrant/action/builtin/box_add.rb +12 -1
- data/lib/vagrant/action/builtin/confirm.rb +1 -0
- data/lib/vagrant/action/builtin/graceful_halt.rb +9 -5
- data/lib/vagrant/action/builtin/handle_box_url.rb +16 -7
- data/lib/vagrant/action/builtin/handle_forwarded_port_collisions.rb +1 -1
- data/lib/vagrant/action/builtin/mixin_provisioners.rb +43 -0
- data/lib/vagrant/action/builtin/nfs.rb +18 -8
- data/lib/vagrant/action/builtin/provision.rb +30 -21
- data/lib/vagrant/action/builtin/provisioner_cleanup.rb +35 -0
- data/lib/vagrant/action/builtin/wait_for_communicator.rb +84 -0
- data/lib/vagrant/action/warden.rb +2 -1
- data/lib/vagrant/box_collection.rb +62 -44
- data/lib/vagrant/cli.rb +1 -9
- data/lib/vagrant/config/v2/root.rb +6 -0
- data/lib/vagrant/environment.rb +27 -51
- data/lib/vagrant/errors.rb +33 -1
- data/lib/vagrant/guest.rb +2 -2
- data/lib/vagrant/machine.rb +14 -22
- data/lib/vagrant/plugin/v2/command.rb +4 -1
- data/lib/vagrant/plugin/v2/communicator.rb +21 -0
- data/lib/vagrant/plugin/v2/guest.rb +1 -56
- data/lib/vagrant/plugin/v2/provisioner.rb +6 -0
- data/lib/vagrant/util/downloader.rb +7 -2
- data/lib/vagrant/util/platform.rb +43 -0
- data/lib/vagrant/util/ssh.rb +5 -0
- data/lib/vagrant/util/subprocess.rb +16 -2
- data/lib/vagrant/version.rb +1 -1
- data/plugins/commands/box/command/remove.rb +22 -2
- data/plugins/commands/box/command/repackage.rb +1 -1
- data/plugins/commands/destroy/command.rb +8 -3
- data/plugins/commands/help/command.rb +12 -0
- data/plugins/commands/help/plugin.rb +17 -0
- data/plugins/commands/plugin/action.rb +11 -0
- data/plugins/commands/plugin/action/install_gem.rb +26 -1
- data/plugins/commands/plugin/action/plugin_exists_check.rb +26 -0
- data/plugins/commands/plugin/command/install.rb +4 -21
- data/plugins/commands/plugin/command/mixin_install_opts.rb +30 -0
- data/plugins/commands/plugin/command/root.rb +5 -0
- data/plugins/commands/plugin/command/update.rb +41 -0
- data/plugins/commands/reload/command.rb +4 -0
- data/plugins/commands/status/command.rb +6 -1
- data/plugins/commands/up/command.rb +10 -0
- data/plugins/commands/up/start_mixins.rb +12 -1
- data/plugins/communicators/ssh/communicator.rb +61 -6
- data/plugins/guests/arch/cap/change_host_name.rb +1 -2
- data/plugins/guests/arch/cap/configure_networks.rb +6 -0
- data/plugins/guests/coreos/cap/change_host_name.rb +15 -0
- data/plugins/guests/coreos/cap/configure_networks.rb +72 -0
- data/plugins/guests/coreos/guest.rb +9 -0
- data/plugins/guests/coreos/plugin.rb +25 -0
- data/plugins/guests/darwin/cap/change_host_name.rb +14 -0
- data/plugins/guests/darwin/cap/configure_networks.rb +52 -0
- data/plugins/guests/darwin/cap/halt.rb +16 -0
- data/plugins/guests/darwin/cap/mount_nfs_folder.rb +25 -0
- data/plugins/guests/darwin/cap/mount_vmware_shared_folder.rb +36 -0
- data/plugins/guests/darwin/cap/shell_expand_guest_path.rb +26 -0
- data/plugins/guests/darwin/cap/verify_vmware_hgfs.rb +12 -0
- data/plugins/guests/darwin/guest.rb +15 -0
- data/plugins/guests/darwin/plugin.rb +50 -0
- data/plugins/guests/debian/cap/change_host_name.rb +1 -0
- data/plugins/guests/gentoo/guest.rb +1 -1
- data/plugins/guests/linux/cap/mount_nfs.rb +9 -1
- data/plugins/guests/linux/cap/mount_virtualbox_shared_folder.rb +26 -7
- data/plugins/guests/linux/cap/shell_expand_guest_path.rb +4 -1
- data/plugins/guests/openbsd/cap/change_host_name.rb +14 -0
- data/plugins/guests/openbsd/cap/configure_networks.rb +40 -0
- data/plugins/guests/openbsd/cap/mount_nfs_folder.rb +14 -0
- data/plugins/guests/openbsd/plugin.rb +15 -0
- data/plugins/guests/solaris/cap/halt.rb +2 -1
- data/plugins/guests/solaris/cap/mount_virtualbox_shared_folder.rb +4 -1
- data/plugins/guests/solaris11/cap/change_host_name.rb +25 -0
- data/plugins/guests/solaris11/cap/configure_networks.rb +32 -0
- data/plugins/guests/solaris11/cap/halt.rb +26 -0
- data/plugins/guests/solaris11/cap/mount_virtualbox_shared_folder.rb +35 -0
- data/plugins/guests/solaris11/config.rb +22 -0
- data/plugins/guests/solaris11/guest.rb +15 -0
- data/plugins/guests/solaris11/plugin.rb +44 -0
- data/plugins/guests/suse/cap/configure_networks.rb +60 -0
- data/plugins/guests/suse/plugin.rb +5 -0
- data/plugins/guests/ubuntu/cap/change_host_name.rb +1 -0
- data/plugins/guests/ubuntu/cap/mount_nfs.rb +19 -0
- data/plugins/guests/ubuntu/cap/mount_virtualbox_shared_folder.rb +14 -0
- data/plugins/guests/ubuntu/guest.rb +0 -19
- data/plugins/guests/ubuntu/plugin.rb +10 -0
- data/plugins/hosts/arch/host.rb +5 -28
- data/plugins/hosts/bsd/host.rb +83 -7
- data/plugins/hosts/fedora/host.rb +12 -6
- data/plugins/hosts/gentoo/host.rb +3 -1
- data/plugins/hosts/linux/host.rb +42 -9
- data/plugins/hosts/opensuse/host.rb +3 -1
- data/plugins/hosts/slackware/host.rb +26 -0
- data/plugins/hosts/slackware/plugin.rb +15 -0
- data/plugins/kernel_v1/config/ssh.rb +2 -2
- data/plugins/kernel_v2/config/ssh.rb +8 -16
- data/plugins/kernel_v2/config/vm.rb +68 -11
- data/plugins/providers/virtualbox/action.rb +15 -2
- data/plugins/providers/virtualbox/action/boot.rb +0 -26
- data/plugins/providers/virtualbox/action/clear_network_interfaces.rb +1 -1
- data/plugins/providers/virtualbox/action/customize.rb +10 -3
- data/plugins/providers/virtualbox/action/destroy_unused_network_interfaces.rb +8 -1
- data/plugins/providers/virtualbox/action/forward_ports.rb +1 -0
- data/plugins/providers/virtualbox/action/import.rb +3 -0
- data/plugins/providers/virtualbox/action/network.rb +14 -2
- data/plugins/providers/virtualbox/action/prepare_nfs_settings.rb +7 -2
- data/plugins/providers/virtualbox/action/set_name.rb +13 -1
- data/plugins/providers/virtualbox/config.rb +39 -2
- data/plugins/providers/virtualbox/driver/base.rb +5 -0
- data/plugins/providers/virtualbox/driver/meta.rb +7 -1
- data/plugins/providers/virtualbox/driver/version_4_0.rb +2 -2
- data/plugins/providers/virtualbox/driver/version_4_1.rb +2 -2
- data/plugins/providers/virtualbox/driver/version_4_2.rb +17 -0
- data/plugins/providers/virtualbox/model/forwarded_port.rb +7 -1
- data/plugins/providers/virtualbox/util/compile_forwarded_ports.rb +5 -1
- data/plugins/provisioners/ansible/config.rb +40 -23
- data/plugins/provisioners/ansible/provisioner.rb +68 -13
- data/plugins/provisioners/cfengine/cap/debian/cfengine_install.rb +1 -1
- data/plugins/provisioners/cfengine/cap/redhat/cfengine_install.rb +1 -1
- data/plugins/provisioners/cfengine/config.rb +7 -1
- data/plugins/provisioners/cfengine/provisioner.rb +4 -5
- data/plugins/provisioners/chef/config/base.rb +31 -0
- data/plugins/provisioners/chef/config/chef_client.rb +15 -6
- data/plugins/provisioners/chef/config/chef_solo.rb +18 -11
- data/plugins/provisioners/chef/provisioner/base.rb +23 -3
- data/plugins/provisioners/chef/provisioner/chef_client.rb +25 -6
- data/plugins/provisioners/chef/provisioner/chef_solo.rb +16 -13
- data/plugins/provisioners/file/config.rb +29 -0
- data/plugins/provisioners/file/plugin.rb +23 -0
- data/plugins/provisioners/file/provisioner.rb +16 -0
- data/plugins/provisioners/puppet/config/puppet.rb +4 -1
- data/plugins/provisioners/puppet/provisioner/puppet.rb +15 -9
- data/plugins/provisioners/puppet/provisioner/puppet_server.rb +9 -2
- data/plugins/provisioners/salt/bootstrap-salt.sh +6 -0
- data/plugins/provisioners/salt/config.rb +105 -0
- data/plugins/provisioners/salt/errors.rb +11 -0
- data/plugins/provisioners/salt/plugin.rb +22 -0
- data/plugins/provisioners/salt/provisioner.rb +249 -0
- data/plugins/provisioners/shell/config.rb +11 -2
- data/plugins/provisioners/shell/provisioner.rb +15 -3
- data/scripts/website_push_docs.sh +12 -0
- data/scripts/website_push_www.sh +12 -0
- data/templates/commands/init/Vagrantfile.erb +5 -2
- data/templates/commands/ssh_config/config.erb +4 -0
- data/templates/guests/coreos/etcd.service.erb +10 -0
- data/templates/guests/fedora/network_static.erb +2 -3
- data/templates/guests/openbsd/network_dhcp.erb +1 -0
- data/templates/guests/openbsd/network_static.erb +1 -0
- data/templates/guests/suse/network_dhcp.erb +6 -0
- data/templates/guests/suse/network_static.erb +10 -0
- data/templates/locales/en.yml +123 -13
- data/templates/nfs/exports.erb +4 -4
- data/templates/nfs/exports_freebsd.erb +4 -4
- data/templates/nfs/exports_linux.erb +5 -3
- data/templates/provisioners/chef_client/client.erb +9 -0
- data/templates/provisioners/chef_solo/solo.erb +19 -1
- data/test/unit/vagrant/action/builtin/graceful_halt_test.rb +1 -2
- data/test/unit/vagrant/cli_test.rb +1 -0
- data/test/unit/vagrant/config/v2/root_test.rb +18 -0
- data/test/unit/vagrant/environment_test.rb +25 -0
- data/test/unit/vagrant/util/downloader_test.rb +4 -4
- data/test/unit/vagrant_test.rb +18 -0
- data/website/docs/.buildpacks +2 -0
- data/website/docs/Gemfile +13 -0
- data/website/docs/Gemfile.lock +141 -0
- data/website/docs/Procfile +1 -0
- data/website/docs/README.md +26 -0
- data/website/docs/config.rb +78 -0
- data/website/docs/config.ru +44 -0
- data/website/docs/helpers/sidebar_helpers.rb +19 -0
- data/website/docs/lib/redirect_to_latest.rb +25 -0
- data/website/docs/lib/redirect_v1_docs.rb +26 -0
- data/website/docs/source/404.html.erb +7 -0
- data/website/docs/source/images/bullet_1.png +0 -0
- data/website/docs/source/images/bullet_2.png +0 -0
- data/website/docs/source/images/bullet_3.png +0 -0
- data/website/docs/source/images/customers.png +0 -0
- data/website/docs/source/images/customers_small.png +0 -0
- data/website/docs/source/images/footer_background.png +0 -0
- data/website/docs/source/images/footer_hashi_logo.png +0 -0
- data/website/docs/source/images/footer_vagrant_logo.png +0 -0
- data/website/docs/source/images/get_started_background.png +0 -0
- data/website/docs/source/images/icon_caution.png +0 -0
- data/website/docs/source/images/logo_docs.png +0 -0
- data/website/docs/source/images/logo_docs_small.png +0 -0
- data/website/docs/source/images/logo_small.png +0 -0
- data/website/docs/source/images/logo_vagrant.png +0 -0
- data/website/docs/source/images/open_close.png +0 -0
- data/website/docs/source/images/search_icon.png +0 -0
- data/website/docs/source/images/sidebar_background_docs.png +0 -0
- data/website/docs/source/images/sidebar_background_inner.png +0 -0
- data/website/docs/source/images/steps_background.png +0 -0
- data/website/docs/source/images/vagrant_header_background.png +0 -0
- data/website/docs/source/index.html.erb +0 -0
- data/website/docs/source/javascripts/backstretch.js +4 -0
- data/website/docs/source/javascripts/bootstrap.min.js +7 -0
- data/website/docs/source/javascripts/fittext.js +43 -0
- data/website/docs/source/javascripts/grid-overlay.js +161 -0
- data/website/docs/source/javascripts/jquery.js +2 -0
- data/website/docs/source/javascripts/less-1.3.0.min.js +9 -0
- data/website/docs/source/javascripts/modernizr.js +1384 -0
- data/website/docs/source/javascripts/vagrantup.js +15 -0
- data/website/docs/source/layouts/layout.erb +266 -0
- data/website/docs/source/stylesheets/_base.less +317 -0
- data/website/docs/source/stylesheets/_components.less +74 -0
- data/website/docs/source/stylesheets/_footer.less +101 -0
- data/website/docs/source/stylesheets/_media-queries.less +452 -0
- data/website/docs/source/stylesheets/_mixins.less +174 -0
- data/website/docs/source/stylesheets/_nav.less +71 -0
- data/website/docs/source/stylesheets/_pages.less +276 -0
- data/website/docs/source/stylesheets/_sidebar.less +136 -0
- data/website/docs/source/stylesheets/_type.less +36 -0
- data/website/docs/source/stylesheets/_variables.less +39 -0
- data/website/docs/source/stylesheets/bootstrap.css +5946 -0
- data/website/docs/source/stylesheets/vagrantup.less +16 -0
- data/website/docs/source/v2/boxes.html.md +78 -0
- data/website/docs/source/v2/boxes/format.html.md +32 -0
- data/website/docs/source/v2/cli/box.html.md +62 -0
- data/website/docs/source/v2/cli/destroy.html.md +20 -0
- data/website/docs/source/v2/cli/halt.html.md +19 -0
- data/website/docs/source/v2/cli/index.html.md +24 -0
- data/website/docs/source/v2/cli/init.html.md +18 -0
- data/website/docs/source/v2/cli/package.html.md +43 -0
- data/website/docs/source/v2/cli/plugin.html.md +56 -0
- data/website/docs/source/v2/cli/provision.html.md +24 -0
- data/website/docs/source/v2/cli/reload.html.md +27 -0
- data/website/docs/source/v2/cli/resume.html.md +11 -0
- data/website/docs/source/v2/cli/ssh.html.md +24 -0
- data/website/docs/source/v2/cli/ssh_config.html.md +16 -0
- data/website/docs/source/v2/cli/status.html.md +14 -0
- data/website/docs/source/v2/cli/suspend.html.md +19 -0
- data/website/docs/source/v2/cli/up.html.md +34 -0
- data/website/docs/source/v2/debugging.html.md +42 -0
- data/website/docs/source/v2/getting-started/boxes.html.md +56 -0
- data/website/docs/source/v2/getting-started/index.html.md +43 -0
- data/website/docs/source/v2/getting-started/networking.html.md +45 -0
- data/website/docs/source/v2/getting-started/project_setup.html.md +38 -0
- data/website/docs/source/v2/getting-started/providers.html.md +37 -0
- data/website/docs/source/v2/getting-started/provisioning.html.md +75 -0
- data/website/docs/source/v2/getting-started/rebuild.html.md +17 -0
- data/website/docs/source/v2/getting-started/synced_folders.html.md +42 -0
- data/website/docs/source/v2/getting-started/teardown.html.md +41 -0
- data/website/docs/source/v2/getting-started/up.html.md +35 -0
- data/website/docs/source/v2/index.html.md +10 -0
- data/website/docs/source/v2/installation/backwards-compatibility.html.md +35 -0
- data/website/docs/source/v2/installation/index.html.md +28 -0
- data/website/docs/source/v2/installation/uninstallation.html.md +39 -0
- data/website/docs/source/v2/installation/upgrading-from-1-0.html.md +26 -0
- data/website/docs/source/v2/installation/upgrading.html.md +20 -0
- data/website/docs/source/v2/multi-machine/index.html.md +105 -0
- data/website/docs/source/v2/networking/basic_usage.html.md +43 -0
- data/website/docs/source/v2/networking/forwarded_ports.html.md +57 -0
- data/website/docs/source/v2/networking/index.html.md +40 -0
- data/website/docs/source/v2/networking/private_network.html.md +48 -0
- data/website/docs/source/v2/networking/public_network.html.md +53 -0
- data/website/docs/source/v2/plugins/commands.html.md +116 -0
- data/website/docs/source/v2/plugins/configuration.html.md +166 -0
- data/website/docs/source/v2/plugins/development-basics.html.md +139 -0
- data/website/docs/source/v2/plugins/guest-capabilities.html.md +100 -0
- data/website/docs/source/v2/plugins/guests.html.md +99 -0
- data/website/docs/source/v2/plugins/hosts.html.md +46 -0
- data/website/docs/source/v2/plugins/index.html.md +21 -0
- data/website/docs/source/v2/plugins/packaging.html.md +102 -0
- data/website/docs/source/v2/plugins/providers.html.md +234 -0
- data/website/docs/source/v2/plugins/provisioners.html.md +64 -0
- data/website/docs/source/v2/plugins/usage.html.md +58 -0
- data/website/docs/source/v2/providers/basic_usage.html.md +67 -0
- data/website/docs/source/v2/providers/configuration.html.md +89 -0
- data/website/docs/source/v2/providers/custom.html.md +9 -0
- data/website/docs/source/v2/providers/default.html.md +22 -0
- data/website/docs/source/v2/providers/index.html.md +23 -0
- data/website/docs/source/v2/providers/installation.html.md +11 -0
- data/website/docs/source/v2/provisioning/ansible.html.md +144 -0
- data/website/docs/source/v2/provisioning/basic_usage.html.md +67 -0
- data/website/docs/source/v2/provisioning/chef_client.html.md +109 -0
- data/website/docs/source/v2/provisioning/chef_solo.html.md +156 -0
- data/website/docs/source/v2/provisioning/index.html.md +28 -0
- data/website/docs/source/v2/provisioning/puppet_agent.html.md +70 -0
- data/website/docs/source/v2/provisioning/puppet_apply.html.md +114 -0
- data/website/docs/source/v2/provisioning/shell.html.md +88 -0
- data/website/docs/source/v2/synced-folders/basic_usage.html.md +53 -0
- data/website/docs/source/v2/synced-folders/index.html.md +17 -0
- data/website/docs/source/v2/synced-folders/nfs.html.md +53 -0
- data/website/docs/source/v2/vagrantfile/index.html.md +75 -0
- data/website/docs/source/v2/vagrantfile/machine_settings.html.md +84 -0
- data/website/docs/source/v2/vagrantfile/ssh_settings.html.md +61 -0
- data/website/docs/source/v2/vagrantfile/vagrant_settings.html.md +19 -0
- data/website/docs/source/v2/vagrantfile/version.html.md +64 -0
- data/website/docs/source/v2/virtualbox/boxes.html.md +71 -0
- data/website/docs/source/v2/virtualbox/configuration.html.md +63 -0
- data/website/docs/source/v2/virtualbox/index.html.md +21 -0
- data/website/docs/source/v2/virtualbox/usage.html.md +12 -0
- data/website/docs/source/v2/vmware/boxes.html.md +107 -0
- data/website/docs/source/v2/vmware/configuration.html.md +91 -0
- data/website/docs/source/v2/vmware/index.html.md +30 -0
- data/website/docs/source/v2/vmware/installation.html.md +40 -0
- data/website/docs/source/v2/vmware/known-issues.html.md +21 -0
- data/website/docs/source/v2/vmware/usage.html.md +27 -0
- data/website/docs/source/v2/why-vagrant/index.html.md +46 -0
- data/website/www/.buildpacks +2 -0
- data/website/www/Gemfile +15 -0
- data/website/www/Gemfile.lock +123 -0
- data/website/www/Procfile +1 -0
- data/website/www/README.md +26 -0
- data/website/www/config.rb +88 -0
- data/website/www/config.ru +39 -0
- data/website/www/helpers/sidebar_helpers.rb +12 -0
- data/website/www/lib/legacy_redirect.rb +32 -0
- data/website/www/source/404.html.erb +11 -0
- data/website/www/source/_sidebar_about.erb +5 -0
- data/website/www/source/_sidebar_blog.erb +11 -0
- data/website/www/source/_sidebar_support.html.erb +6 -0
- data/website/www/source/about.html.markdown +16 -0
- data/website/www/source/blog.html.erb +34 -0
- data/website/www/source/blog/2013-09-16-test.html.markdown +26 -0
- data/website/www/source/blog_feed.xml.builder +23 -0
- data/website/www/source/images/bullet_1.png +0 -0
- data/website/www/source/images/bullet_2.png +0 -0
- data/website/www/source/images/bullet_3.png +0 -0
- data/website/www/source/images/customers.png +0 -0
- data/website/www/source/images/customers_small.png +0 -0
- data/website/www/source/images/footer_background.png +0 -0
- data/website/www/source/images/footer_hashi_logo.png +0 -0
- data/website/www/source/images/footer_vagrant_logo.png +0 -0
- data/website/www/source/images/get_started_background.png +0 -0
- data/website/www/source/images/icon_caution.png +0 -0
- data/website/www/source/images/logo_docs.png +0 -0
- data/website/www/source/images/logo_docs_small.png +0 -0
- data/website/www/source/images/logo_small.png +0 -0
- data/website/www/source/images/logo_vagrant.png +0 -0
- data/website/www/source/images/open_close.png +0 -0
- data/website/www/source/images/search_icon.png +0 -0
- data/website/www/source/images/sidebar_background_docs.png +0 -0
- data/website/www/source/images/sidebar_background_inner.png +0 -0
- data/website/www/source/images/sponsors/fastly.png +0 -0
- data/website/www/source/images/sponsors/kiip.png +0 -0
- data/website/www/source/images/sponsors/softlayer.jpg +0 -0
- data/website/www/source/images/sponsors/typekit.png +0 -0
- data/website/www/source/images/steps_background.png +0 -0
- data/website/www/source/images/vagrant_header_background.png +0 -0
- data/website/www/source/images/vagrant_vmware_background.png +0 -0
- data/website/www/source/index.html.erb +109 -0
- data/website/www/source/javascripts/backstretch.js +4 -0
- data/website/www/source/javascripts/bootstrap.min.js +7 -0
- data/website/www/source/javascripts/fittext.js +43 -0
- data/website/www/source/javascripts/grid-overlay.js +161 -0
- data/website/www/source/javascripts/jquery.js +2 -0
- data/website/www/source/javascripts/less-1.3.0.min.js +9 -0
- data/website/www/source/javascripts/modernizr.js +1384 -0
- data/website/www/source/javascripts/vagrantup.js +58 -0
- data/website/www/source/layouts/blog_post.erb +42 -0
- data/website/www/source/layouts/inner.erb +34 -0
- data/website/www/source/layouts/layout.erb +107 -0
- data/website/www/source/sponsors.html.erb +23 -0
- data/website/www/source/stylesheets/_base.less +326 -0
- data/website/www/source/stylesheets/_components.less +74 -0
- data/website/www/source/stylesheets/_footer.less +101 -0
- data/website/www/source/stylesheets/_media-queries.less +549 -0
- data/website/www/source/stylesheets/_mixins.less +175 -0
- data/website/www/source/stylesheets/_modules.less +37 -0
- data/website/www/source/stylesheets/_nav.less +74 -0
- data/website/www/source/stylesheets/_pages.less +467 -0
- data/website/www/source/stylesheets/_sidebar.less +137 -0
- data/website/www/source/stylesheets/_type.less +36 -0
- data/website/www/source/stylesheets/_variables.less +39 -0
- data/website/www/source/stylesheets/bootstrap.css +5946 -0
- data/website/www/source/stylesheets/vagrantup.less +17 -0
- data/website/www/source/support.html.erb +25 -0
- data/website/www/source/support/community.html.erb +28 -0
- data/website/www/source/support/professional.html.erb +17 -0
- data/website/www/source/vmware/eula.html.md +21 -0
- data/website/www/source/vmware/index.html.erb +185 -0
- data/website/www/source/vmware/privacy-policy.html.md +71 -0
- data/website/www/source/vmware/terms-of-service.html.md +50 -0
- metadata +436 -186
@@ -15,10 +15,14 @@ module VagrantPlugins
|
|
15
15
|
if type == :forwarded_port
|
16
16
|
guest_port = options[:guest]
|
17
17
|
host_port = options[:host]
|
18
|
+
protocol = options[:protocol] || "tcp"
|
18
19
|
options = scoped_hash_override(options, :virtualbox)
|
19
20
|
id = options[:id]
|
20
21
|
|
21
|
-
|
22
|
+
# If the forwarded port was marked as disabled, ignore.
|
23
|
+
next if options[:disabled]
|
24
|
+
|
25
|
+
mappings[host_port.to_s + protocol.to_s] =
|
22
26
|
Model::ForwardedPort.new(id, host_port, guest_port, options)
|
23
27
|
end
|
24
28
|
end
|
@@ -3,37 +3,54 @@ module VagrantPlugins
|
|
3
3
|
class Config < Vagrant.plugin("2", :config)
|
4
4
|
attr_accessor :playbook
|
5
5
|
attr_accessor :extra_vars
|
6
|
-
attr_accessor :
|
6
|
+
attr_accessor :inventory_path
|
7
7
|
attr_accessor :ask_sudo_pass
|
8
8
|
attr_accessor :limit
|
9
9
|
attr_accessor :sudo
|
10
10
|
attr_accessor :sudo_user
|
11
11
|
attr_accessor :verbose
|
12
|
+
attr_accessor :tags
|
13
|
+
attr_accessor :skip_tags
|
14
|
+
attr_accessor :start_at_task
|
15
|
+
attr_accessor :host_key_checking
|
16
|
+
|
17
|
+
# Joker attribute, used to pass unsupported arguments to ansible anyway
|
18
|
+
attr_accessor :raw_arguments
|
12
19
|
|
13
20
|
def initialize
|
14
|
-
@playbook
|
15
|
-
@extra_vars
|
16
|
-
@
|
17
|
-
@ask_sudo_pass
|
18
|
-
@limit
|
19
|
-
@sudo
|
20
|
-
@sudo_user
|
21
|
-
@verbose
|
21
|
+
@playbook = UNSET_VALUE
|
22
|
+
@extra_vars = UNSET_VALUE
|
23
|
+
@inventory_path = UNSET_VALUE
|
24
|
+
@ask_sudo_pass = UNSET_VALUE
|
25
|
+
@limit = UNSET_VALUE
|
26
|
+
@sudo = UNSET_VALUE
|
27
|
+
@sudo_user = UNSET_VALUE
|
28
|
+
@verbose = UNSET_VALUE
|
29
|
+
@tags = UNSET_VALUE
|
30
|
+
@skip_tags = UNSET_VALUE
|
31
|
+
@start_at_task = UNSET_VALUE
|
32
|
+
@raw_arguments = UNSET_VALUE
|
33
|
+
@host_key_checking = "true"
|
22
34
|
end
|
23
35
|
|
24
36
|
def finalize!
|
25
|
-
@playbook
|
26
|
-
@extra_vars
|
27
|
-
@
|
28
|
-
@ask_sudo_pass
|
29
|
-
@limit
|
30
|
-
@sudo
|
31
|
-
@sudo_user
|
32
|
-
@verbose
|
37
|
+
@playbook = nil if @playbook == UNSET_VALUE
|
38
|
+
@extra_vars = nil if @extra_vars == UNSET_VALUE
|
39
|
+
@inventory_path = nil if @inventory_path == UNSET_VALUE
|
40
|
+
@ask_sudo_pass = nil if @ask_sudo_pass == UNSET_VALUE
|
41
|
+
@limit = nil if @limit == UNSET_VALUE
|
42
|
+
@sudo = nil if @sudo == UNSET_VALUE
|
43
|
+
@sudo_user = nil if @sudo_user == UNSET_VALUE
|
44
|
+
@verbose = nil if @verbose == UNSET_VALUE
|
45
|
+
@tags = nil if @tags == UNSET_VALUE
|
46
|
+
@skip_tags = nil if @skip_tags == UNSET_VALUE
|
47
|
+
@start_at_task = nil if @start_at_task == UNSET_VALUE
|
48
|
+
@raw_arguments = nil if @raw_arguments == UNSET_VALUE
|
49
|
+
@host_key_checking = nil if @host_key_checking == UNSET_VALUE
|
33
50
|
end
|
34
51
|
|
35
52
|
def validate(machine)
|
36
|
-
errors =
|
53
|
+
errors = _detected_errors
|
37
54
|
|
38
55
|
# Validate that a playbook path was provided
|
39
56
|
if !playbook
|
@@ -56,11 +73,11 @@ module VagrantPlugins
|
|
56
73
|
end
|
57
74
|
end
|
58
75
|
|
59
|
-
# Validate the existence of the
|
60
|
-
if
|
61
|
-
expanded_path = Pathname.new(
|
62
|
-
if !expanded_path.
|
63
|
-
errors << I18n.t("vagrant.provisioners.ansible.
|
76
|
+
# Validate the existence of the inventory_path, if specified
|
77
|
+
if inventory_path
|
78
|
+
expanded_path = Pathname.new(inventory_path).expand_path(machine.env.root_path)
|
79
|
+
if !expanded_path.exist?
|
80
|
+
errors << I18n.t("vagrant.provisioners.ansible.inventory_path_invalid",
|
64
81
|
:path => expanded_path)
|
65
82
|
end
|
66
83
|
end
|
@@ -4,42 +4,97 @@ module VagrantPlugins
|
|
4
4
|
def provision
|
5
5
|
ssh = @machine.ssh_info
|
6
6
|
|
7
|
+
# Connect with Vagrant user (unless --user or --private-key are overidden by 'raw_arguments')
|
7
8
|
options = %W[--private-key=#{ssh[:private_key_path]} --user=#{ssh[:username]}]
|
8
|
-
options << "--extra-vars=" + config.extra_vars.map{|k,v| "#{k}=#{v}"}.join(' ') if config.extra_vars
|
9
|
-
options << "--inventory-file=#{config.inventory_file}" if config.inventory_file
|
10
|
-
options << "--ask-sudo-pass" if config.ask_sudo_pass
|
11
9
|
|
12
|
-
|
13
|
-
|
14
|
-
|
10
|
+
# Joker! Not (yet) supported arguments can be passed this way.
|
11
|
+
options << "#{config.raw_arguments}" if config.raw_arguments
|
12
|
+
|
13
|
+
# Append Provisioner options (higher precedence):
|
14
|
+
if config.extra_vars
|
15
|
+
extra_vars = config.extra_vars.map do |k,v|
|
16
|
+
v = v.gsub('"', '\\"')
|
17
|
+
if v.include?(' ')
|
18
|
+
v = v.gsub("'", "\\'")
|
19
|
+
v = "'#{v}'"
|
20
|
+
end
|
21
|
+
|
22
|
+
"#{k}=#{v}"
|
15
23
|
end
|
16
|
-
|
17
|
-
options << "--limit=#{config.limit}"
|
24
|
+
options << "--extra-vars=\"#{extra_vars.join(" ")}\""
|
18
25
|
end
|
19
26
|
|
27
|
+
options << "--inventory-file=#{self.setup_inventory_file}"
|
20
28
|
options << "--sudo" if config.sudo
|
21
29
|
options << "--sudo-user=#{config.sudo_user}" if config.sudo_user
|
22
|
-
options << "
|
30
|
+
options << "#{self.get_verbosity_argument}"
|
31
|
+
options << "--ask-sudo-pass" if config.ask_sudo_pass
|
32
|
+
options << "--tags=#{as_list_argument(config.tags)}" if config.tags
|
33
|
+
options << "--skip-tags=#{as_list_argument(config.skip_tags)}" if config.skip_tags
|
34
|
+
options << "--limit=#{as_list_argument(config.limit)}" if config.limit
|
35
|
+
options << "--start-at-task=#{config.start_at_task}" if config.start_at_task
|
23
36
|
|
24
37
|
# Assemble the full ansible-playbook command
|
25
38
|
command = (%w(ansible-playbook) << options << config.playbook).flatten
|
26
39
|
|
27
40
|
# Write stdout and stderr data, since it's the regular Ansible output
|
28
41
|
command << {
|
29
|
-
:env => {
|
30
|
-
|
42
|
+
:env => {
|
43
|
+
"ANSIBLE_FORCE_COLOR" => "true",
|
44
|
+
"ANSIBLE_HOST_KEY_CHECKING" => "#{config.host_key_checking}"
|
45
|
+
},
|
46
|
+
:notify => [:stdout, :stderr],
|
47
|
+
:workdir => @machine.env.root_path.to_s
|
31
48
|
}
|
32
49
|
|
33
50
|
begin
|
34
|
-
Vagrant::Util::Subprocess.execute(*command) do |type, data|
|
51
|
+
result = Vagrant::Util::Subprocess.execute(*command) do |type, data|
|
35
52
|
if type == :stdout || type == :stderr
|
36
|
-
@machine.env.ui.info(data
|
53
|
+
@machine.env.ui.info(data, :new_line => false, :prefix => false)
|
37
54
|
end
|
38
55
|
end
|
56
|
+
|
57
|
+
raise Vagrant::Errors::AnsibleFailed if result.exit_code != 0
|
39
58
|
rescue Vagrant::Util::Subprocess::LaunchError
|
40
59
|
raise Vagrant::Errors::AnsiblePlaybookAppNotFound
|
41
60
|
end
|
42
61
|
end
|
62
|
+
|
63
|
+
protected
|
64
|
+
|
65
|
+
# Auto-generate "safe" inventory file based on Vagrantfile,
|
66
|
+
# unless inventory_path is explicitly provided
|
67
|
+
def setup_inventory_file
|
68
|
+
return config.inventory_path if config.inventory_path
|
69
|
+
|
70
|
+
ssh = @machine.ssh_info
|
71
|
+
|
72
|
+
generated_inventory_file =
|
73
|
+
@machine.env.root_path.join("vagrant_ansible_inventory_#{machine.name}")
|
74
|
+
|
75
|
+
generated_inventory_file.open('w') do |file|
|
76
|
+
file.write("# Generated by Vagrant\n\n")
|
77
|
+
file.write("#{machine.name} ansible_ssh_host=#{ssh[:host]} ansible_ssh_port=#{ssh[:port]}\n")
|
78
|
+
end
|
79
|
+
|
80
|
+
return generated_inventory_file.to_s
|
81
|
+
end
|
82
|
+
|
83
|
+
def get_verbosity_argument
|
84
|
+
if config.verbose.to_s =~ /^v+$/
|
85
|
+
# Hopefully ansible-playbook accepts "silly" arguments like '-vvvvv', as '-vvv'
|
86
|
+
return "-#{config.verbose}"
|
87
|
+
elsif config.verbose.to_s == 'extra'
|
88
|
+
return '-vvv'
|
89
|
+
else
|
90
|
+
# fall back to default verbosity
|
91
|
+
return '--verbose'
|
92
|
+
end
|
93
|
+
end
|
94
|
+
|
95
|
+
def as_list_argument(v)
|
96
|
+
v.kind_of?(Array) ? v.join(',') : v
|
97
|
+
end
|
43
98
|
end
|
44
99
|
end
|
45
100
|
end
|
@@ -9,7 +9,7 @@ module VagrantPlugins
|
|
9
9
|
comm.sudo("GPGFILE=`tempfile`; wget -O $GPGFILE #{config.repo_gpg_key_url} && apt-key add $GPGFILE; rm -f $GPGFILE")
|
10
10
|
|
11
11
|
comm.sudo("apt-get update")
|
12
|
-
comm.sudo("apt-get install -y
|
12
|
+
comm.sudo("apt-get install -y #{config.package_name}")
|
13
13
|
end
|
14
14
|
end
|
15
15
|
end
|
@@ -14,7 +14,7 @@ module VagrantPlugins
|
|
14
14
|
logger.info("Installing CFEngine Community Yum Repository GPG KEY from #{config.repo_gpg_key_url}")
|
15
15
|
comm.sudo("GPGFILE=$(mktemp) && wget -O $GPGFILE #{config.repo_gpg_key_url} && rpm --import $GPGFILE; rm -f $GPGFILE")
|
16
16
|
|
17
|
-
comm.sudo("yum -y install
|
17
|
+
comm.sudo("yum -y install #{config.package_name}")
|
18
18
|
end
|
19
19
|
end
|
20
20
|
end
|
@@ -20,6 +20,7 @@ module VagrantPlugins
|
|
20
20
|
attr_accessor :upload_path
|
21
21
|
attr_accessor :yum_repo_file
|
22
22
|
attr_accessor :yum_repo_url
|
23
|
+
attr_accessor :package_name
|
23
24
|
|
24
25
|
def initialize
|
25
26
|
@am_policy_hub = UNSET_VALUE
|
@@ -37,6 +38,7 @@ module VagrantPlugins
|
|
37
38
|
@upload_path = UNSET_VALUE
|
38
39
|
@yum_repo_file = UNSET_VALUE
|
39
40
|
@yum_repo_url = UNSET_VALUE
|
41
|
+
@package_name = UNSET_VALUE
|
40
42
|
end
|
41
43
|
|
42
44
|
def finalize!
|
@@ -81,10 +83,14 @@ module VagrantPlugins
|
|
81
83
|
if @yum_repo_url == UNSET_VALUE
|
82
84
|
@yum_repo_url = "http://cfengine.com/pub/yum/"
|
83
85
|
end
|
86
|
+
|
87
|
+
if @package_name == UNSET_VALUE
|
88
|
+
@package_name = "cfengine-community"
|
89
|
+
end
|
84
90
|
end
|
85
91
|
|
86
92
|
def validate(machine)
|
87
|
-
errors =
|
93
|
+
errors = _detected_errors
|
88
94
|
|
89
95
|
valid_modes = [:bootstrap, :single_run]
|
90
96
|
errors << I18n.t("vagrant.cfengine_config.invalid_mode") if !valid_modes.include?(@mode)
|
@@ -41,10 +41,9 @@ module VagrantPlugins
|
|
41
41
|
if [:stderr, :stdout].include?(type)
|
42
42
|
# Output the data with the proper color based on the stream.
|
43
43
|
color = type == :stdout ? :green : :red
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
@machine.ui.info(data.chomp, :color => color, :prefix => false)
|
44
|
+
@machine.ui.info(
|
45
|
+
data,
|
46
|
+
:color => color, :new_line => false, :prefix => false)
|
48
47
|
end
|
49
48
|
end
|
50
49
|
end
|
@@ -87,7 +86,7 @@ module VagrantPlugins
|
|
87
86
|
|
88
87
|
@machine.ui.info(I18n.t("vagrant.cfengine_bootstrapping",
|
89
88
|
policy_server: policy_server_address))
|
90
|
-
result = cfagent("--bootstrap
|
89
|
+
result = cfagent("--bootstrap #{policy_server_address}", error_check: false)
|
91
90
|
raise Vagrant::Errors::CFEngineBootstrapFailed if result != 0
|
92
91
|
|
93
92
|
# Policy hubs need to do additional things before they're ready
|
@@ -6,6 +6,8 @@ module VagrantPlugins
|
|
6
6
|
attr_accessor :attempts
|
7
7
|
attr_accessor :binary_path
|
8
8
|
attr_accessor :binary_env
|
9
|
+
attr_accessor :custom_config_path
|
10
|
+
attr_accessor :formatter
|
9
11
|
attr_accessor :http_proxy
|
10
12
|
attr_accessor :http_proxy_user
|
11
13
|
attr_accessor :http_proxy_pass
|
@@ -18,6 +20,9 @@ module VagrantPlugins
|
|
18
20
|
attr_accessor :node_name
|
19
21
|
attr_accessor :provisioning_path
|
20
22
|
attr_accessor :run_list
|
23
|
+
attr_accessor :file_cache_path
|
24
|
+
attr_accessor :file_backup_path
|
25
|
+
attr_accessor :verbose_logging
|
21
26
|
|
22
27
|
def initialize
|
23
28
|
super
|
@@ -26,6 +31,8 @@ module VagrantPlugins
|
|
26
31
|
@attempts = UNSET_VALUE
|
27
32
|
@binary_path = UNSET_VALUE
|
28
33
|
@binary_env = UNSET_VALUE
|
34
|
+
@custom_config_path = UNSET_VALUE
|
35
|
+
@formatter = UNSET_VALUE
|
29
36
|
@http_proxy = UNSET_VALUE
|
30
37
|
@http_proxy_user = UNSET_VALUE
|
31
38
|
@http_proxy_pass = UNSET_VALUE
|
@@ -36,6 +43,9 @@ module VagrantPlugins
|
|
36
43
|
@no_proxy = UNSET_VALUE
|
37
44
|
@node_name = UNSET_VALUE
|
38
45
|
@provisioning_path = UNSET_VALUE
|
46
|
+
@file_cache_path = UNSET_VALUE
|
47
|
+
@file_backup_path = UNSET_VALUE
|
48
|
+
@verbose_logging = UNSET_VALUE
|
39
49
|
|
40
50
|
@json = {}
|
41
51
|
@run_list = []
|
@@ -46,6 +56,8 @@ module VagrantPlugins
|
|
46
56
|
@attempts = 1 if @attempts == UNSET_VALUE
|
47
57
|
@binary_path = nil if @binary_path == UNSET_VALUE
|
48
58
|
@binary_env = nil if @binary_env == UNSET_VALUE
|
59
|
+
@custom_config_path = nil if @custom_config_path == UNSET_VALUE
|
60
|
+
@formatter = nil if @formatter == UNSET_VALUE
|
49
61
|
@http_proxy = nil if @http_proxy == UNSET_VALUE
|
50
62
|
@http_proxy_user = nil if @http_proxy_user == UNSET_VALUE
|
51
63
|
@http_proxy_pass = nil if @http_proxy_pass == UNSET_VALUE
|
@@ -56,6 +68,9 @@ module VagrantPlugins
|
|
56
68
|
@no_proxy = nil if @no_proxy == UNSET_VALUE
|
57
69
|
@node_name = nil if @node_name == UNSET_VALUE
|
58
70
|
@provisioning_path = nil if @provisioning_path == UNSET_VALUE
|
71
|
+
@file_backup_path = "/var/chef/backup" if @file_backup_path == UNSET_VALUE
|
72
|
+
@file_cache_path = "/var/chef/cache" if @file_cache_path == UNSET_VALUE
|
73
|
+
@verbose_logging = false if @verbose_logging == UNSET_VALUE
|
59
74
|
|
60
75
|
# Make sure the log level is a symbol
|
61
76
|
@log_level = @log_level.to_sym
|
@@ -68,6 +83,22 @@ module VagrantPlugins
|
|
68
83
|
end
|
69
84
|
end
|
70
85
|
|
86
|
+
# Just like the normal configuration "validate" method except that
|
87
|
+
# it returns an array of errors that should be merged into some
|
88
|
+
# other error accumulator.
|
89
|
+
def validate_base(machine)
|
90
|
+
errors = _detected_errors
|
91
|
+
|
92
|
+
if @custom_config_path
|
93
|
+
expanded = File.expand_path(@custom_config_path, machine.env.root_path)
|
94
|
+
if !File.file?(expanded)
|
95
|
+
errors << I18n.t("vagrant.config.chef.custom_config_path_missing")
|
96
|
+
end
|
97
|
+
end
|
98
|
+
|
99
|
+
errors
|
100
|
+
end
|
101
|
+
|
71
102
|
# Adds a recipe to the run list
|
72
103
|
def add_recipe(name)
|
73
104
|
name = "recipe[#{name}]" unless name =~ /^recipe\[(.+?)\]$/
|
@@ -1,16 +1,18 @@
|
|
1
1
|
require File.expand_path("../base", __FILE__)
|
2
2
|
|
3
|
+
require "vagrant/util/which"
|
4
|
+
|
3
5
|
module VagrantPlugins
|
4
6
|
module Chef
|
5
7
|
module Config
|
6
8
|
class ChefClient < Base
|
7
9
|
attr_accessor :chef_server_url
|
8
10
|
attr_accessor :client_key_path
|
11
|
+
attr_accessor :delete_client
|
12
|
+
attr_accessor :delete_node
|
9
13
|
attr_accessor :encrypted_data_bag_secret_key_path
|
10
14
|
attr_accessor :encrypted_data_bag_secret
|
11
15
|
attr_accessor :environment
|
12
|
-
attr_accessor :file_cache_path
|
13
|
-
attr_accessor :file_backup_path
|
14
16
|
attr_accessor :validation_key_path
|
15
17
|
attr_accessor :validation_client_name
|
16
18
|
|
@@ -19,11 +21,11 @@ module VagrantPlugins
|
|
19
21
|
|
20
22
|
@chef_server_url = UNSET_VALUE
|
21
23
|
@client_key_path = UNSET_VALUE
|
24
|
+
@delete_client = UNSET_VALUE
|
25
|
+
@delete_node = UNSET_VALUE
|
22
26
|
@encrypted_data_bag_secret_key_path = UNSET_VALUE
|
23
27
|
@encrypted_data_bag_secret = UNSET_VALUE
|
24
28
|
@environment = UNSET_VALUE
|
25
|
-
@file_cache_path = UNSET_VALUE
|
26
|
-
@file_backup_path = UNSET_VALUE
|
27
29
|
@validation_key_path = UNSET_VALUE
|
28
30
|
@validation_client_name = UNSET_VALUE
|
29
31
|
end
|
@@ -33,22 +35,29 @@ module VagrantPlugins
|
|
33
35
|
|
34
36
|
@chef_server_url = nil if @chef_server_url == UNSET_VALUE
|
35
37
|
@client_key_path = "/etc/chef/client.pem" if @client_key_path == UNSET_VALUE
|
38
|
+
@delete_client = false if @delete_client == UNSET_VALUE
|
39
|
+
@delete_node = false if @delete_node == UNSET_VALUE
|
36
40
|
@encrypted_data_bag_secret_key_path = nil if @encrypted_data_bag_secret_key_path == UNSET_VALUE
|
37
41
|
@encrypted_data_bag_secret = "/tmp/encrypted_data_bag_secret" if @encrypted_data_bag_secret == UNSET_VALUE
|
38
42
|
@environment = nil if @environment == UNSET_VALUE
|
39
|
-
@file_backup_path = "/srv/chef/cache" if @file_backup_path == UNSET_VALUE
|
40
|
-
@file_cache_path = "/srv/chef/file_store" if @file_cache_path == UNSET_VALUE
|
41
43
|
@validation_client_name = "chef-validator" if @validation_client_name == UNSET_VALUE
|
42
44
|
@validation_key_path = nil if @validation_key_path == UNSET_VALUE
|
43
45
|
end
|
44
46
|
|
45
47
|
def validate(machine)
|
46
48
|
errors = _detected_errors
|
49
|
+
errors.concat(validate_base(machine))
|
47
50
|
errors << I18n.t("vagrant.config.chef.server_url_empty") if \
|
48
51
|
!chef_server_url || chef_server_url.strip == ""
|
49
52
|
errors << I18n.t("vagrant.config.chef.validation_key_path") if \
|
50
53
|
!validation_key_path
|
51
54
|
|
55
|
+
if delete_client || delete_node
|
56
|
+
if !Vagrant::Util::Which.which("knife")
|
57
|
+
errors << I18n.t("vagrant.chef_config_knife_not_found")
|
58
|
+
end
|
59
|
+
end
|
60
|
+
|
52
61
|
{ "chef client provisioner" => errors }
|
53
62
|
end
|
54
63
|
end
|
@@ -11,19 +11,21 @@ module VagrantPlugins
|
|
11
11
|
attr_accessor :nfs
|
12
12
|
attr_accessor :encrypted_data_bag_secret_key_path
|
13
13
|
attr_accessor :encrypted_data_bag_secret
|
14
|
+
attr_accessor :environments_path
|
15
|
+
attr_accessor :environment
|
14
16
|
|
15
17
|
def initialize
|
16
18
|
super
|
17
19
|
|
18
20
|
@cookbooks_path = UNSET_VALUE
|
19
21
|
@data_bags_path = UNSET_VALUE
|
22
|
+
@environments_path = UNSET_VALUE
|
23
|
+
@environment = UNSET_VALUE
|
20
24
|
@recipe_url = UNSET_VALUE
|
21
25
|
@roles_path = UNSET_VALUE
|
26
|
+
@nfs = UNSET_VALUE
|
22
27
|
@encrypted_data_bag_secret = UNSET_VALUE
|
23
28
|
@encrypted_data_bag_secret_key_path = UNSET_VALUE
|
24
|
-
@nfs = UNSET_VALUE
|
25
|
-
|
26
|
-
@__defaulted_cookbooks_path = false
|
27
29
|
end
|
28
30
|
|
29
31
|
#------------------------------------------------------------
|
@@ -34,34 +36,39 @@ module VagrantPlugins
|
|
34
36
|
super
|
35
37
|
|
36
38
|
@recipe_url = nil if @recipe_url == UNSET_VALUE
|
39
|
+
@environment = nil if @environment == UNSET_VALUE
|
37
40
|
|
38
41
|
if @cookbooks_path == UNSET_VALUE
|
39
42
|
@cookbooks_path = []
|
40
43
|
@cookbooks_path << [:host, "cookbooks"] if !@recipe_url
|
41
44
|
@cookbooks_path << [:vm, "cookbooks"]
|
42
|
-
@__defaulted_cookbooks_path = true
|
43
45
|
end
|
44
46
|
|
45
|
-
@data_bags_path
|
46
|
-
@roles_path
|
47
|
+
@data_bags_path = [] if @data_bags_path == UNSET_VALUE
|
48
|
+
@roles_path = [] if @roles_path == UNSET_VALUE
|
49
|
+
@environments_path = [] if @environments_path == UNSET_VALUE
|
50
|
+
@environments_path = [@environments_path].flatten
|
47
51
|
|
48
52
|
# Make sure the path is an array.
|
49
|
-
@cookbooks_path
|
50
|
-
@data_bags_path
|
51
|
-
@roles_path
|
53
|
+
@cookbooks_path = prepare_folders_config(@cookbooks_path)
|
54
|
+
@data_bags_path = prepare_folders_config(@data_bags_path)
|
55
|
+
@roles_path = prepare_folders_config(@roles_path)
|
56
|
+
@environments_path = prepare_folders_config(@environments_path)
|
52
57
|
|
58
|
+
@nfs = false if @nfs == UNSET_VALUE
|
53
59
|
@encrypted_data_bag_secret = "/tmp/encrypted_data_bag_secret" if \
|
54
60
|
@encrypted_data_bag_secret == UNSET_VALUE
|
55
61
|
@encrypted_data_bag_secret_key_path = nil if \
|
56
62
|
@encrypted_data_bag_secret_key_path == UNSET_VALUE
|
57
|
-
@nfs = false if @nfs == UNSET_VALUE
|
58
63
|
end
|
59
64
|
|
60
65
|
def validate(machine)
|
61
66
|
errors = _detected_errors
|
67
|
+
errors.concat(validate_base(machine))
|
62
68
|
errors << I18n.t("vagrant.config.chef.cookbooks_path_empty") if \
|
63
69
|
!cookbooks_path || [cookbooks_path].flatten.empty?
|
64
|
-
|
70
|
+
errors << I18n.t("vagrant.config.chef.environment_path_required") if \
|
71
|
+
environment && environments_path.empty?
|
65
72
|
{ "chef solo provisioner" => errors }
|
66
73
|
end
|
67
74
|
|