vagrantup 1.0.7 → 1.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (623) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +91 -0
  3. data/LICENSE +2 -2
  4. data/README.md +11 -13
  5. data/bin/vagrant +29 -5
  6. data/config/default.rb +14 -9
  7. data/contrib/bash/completion.sh +3 -0
  8. data/keys/README.md +3 -3
  9. data/lib/vagrant.rb +156 -102
  10. data/lib/vagrant/action.rb +26 -47
  11. data/lib/vagrant/action/builder.rb +49 -23
  12. data/lib/vagrant/action/builtin/box_add.rb +85 -0
  13. data/lib/vagrant/action/builtin/call.rb +67 -0
  14. data/lib/vagrant/action/builtin/config_validate.rb +30 -0
  15. data/lib/vagrant/action/builtin/confirm.rb +38 -0
  16. data/lib/vagrant/action/builtin/env_set.rb +24 -0
  17. data/lib/vagrant/action/builtin/graceful_halt.rb +73 -0
  18. data/lib/vagrant/action/builtin/handle_box_url.rb +43 -0
  19. data/lib/vagrant/action/builtin/handle_forwarded_port_collisions.rb +117 -0
  20. data/lib/vagrant/action/builtin/lock.rb +57 -0
  21. data/lib/vagrant/action/builtin/nfs.rb +117 -0
  22. data/lib/vagrant/action/builtin/provision.rb +70 -0
  23. data/lib/vagrant/action/builtin/set_hostname.rb +27 -0
  24. data/lib/vagrant/action/builtin/ssh_exec.rb +42 -0
  25. data/lib/vagrant/action/builtin/ssh_run.rb +43 -0
  26. data/lib/vagrant/action/general/package.rb +19 -18
  27. data/lib/vagrant/action/hook.rb +103 -0
  28. data/lib/vagrant/action/runner.rb +21 -5
  29. data/lib/vagrant/action/warden.rb +20 -9
  30. data/lib/vagrant/box.rb +75 -26
  31. data/lib/vagrant/box_collection.rb +301 -35
  32. data/lib/vagrant/cli.rb +20 -14
  33. data/lib/vagrant/config.rb +23 -9
  34. data/lib/vagrant/config/loader.rb +131 -36
  35. data/lib/vagrant/config/v1.rb +9 -0
  36. data/lib/vagrant/config/v1/dummy_config.rb +13 -0
  37. data/lib/vagrant/config/v1/loader.rb +105 -0
  38. data/lib/vagrant/config/v1/root.rb +60 -0
  39. data/lib/vagrant/config/v2.rb +9 -0
  40. data/lib/vagrant/config/v2/dummy_config.rb +13 -0
  41. data/lib/vagrant/config/v2/loader.rb +141 -0
  42. data/lib/vagrant/config/v2/root.rb +105 -0
  43. data/lib/vagrant/config/v2/util.rb +21 -0
  44. data/lib/vagrant/config/version_base.rb +80 -0
  45. data/lib/vagrant/downloaders/base.rb +0 -3
  46. data/lib/vagrant/downloaders/file.rb +10 -4
  47. data/lib/vagrant/downloaders/http.rb +29 -10
  48. data/lib/vagrant/environment.rb +447 -240
  49. data/lib/vagrant/errors.rb +138 -97
  50. data/lib/vagrant/hosts.rb +3 -12
  51. data/lib/vagrant/machine.rb +325 -0
  52. data/lib/vagrant/machine_state.rb +45 -0
  53. data/lib/vagrant/plugin.rb +3 -78
  54. data/lib/vagrant/plugin/v1.rb +19 -0
  55. data/lib/vagrant/plugin/v1/command.rb +169 -0
  56. data/lib/vagrant/plugin/v1/communicator.rb +98 -0
  57. data/lib/vagrant/plugin/v1/config.rb +112 -0
  58. data/lib/vagrant/plugin/v1/errors.rb +15 -0
  59. data/lib/vagrant/plugin/v1/guest.rb +92 -0
  60. data/lib/vagrant/plugin/v1/host.rb +66 -0
  61. data/lib/vagrant/plugin/v1/manager.rb +131 -0
  62. data/lib/vagrant/plugin/v1/plugin.rb +229 -0
  63. data/lib/vagrant/plugin/v1/provider.rb +68 -0
  64. data/lib/vagrant/plugin/v1/provisioner.rb +50 -0
  65. data/lib/vagrant/plugin/v2.rb +22 -0
  66. data/lib/vagrant/plugin/v2/command.rb +234 -0
  67. data/lib/vagrant/plugin/v2/communicator.rb +98 -0
  68. data/lib/vagrant/plugin/v2/components.rb +29 -0
  69. data/lib/vagrant/plugin/v2/config.rb +101 -0
  70. data/lib/vagrant/plugin/v2/errors.rb +15 -0
  71. data/lib/vagrant/plugin/v2/guest.rb +92 -0
  72. data/lib/vagrant/plugin/v2/host.rb +66 -0
  73. data/lib/vagrant/plugin/v2/manager.rb +158 -0
  74. data/lib/vagrant/plugin/v2/plugin.rb +217 -0
  75. data/lib/vagrant/plugin/v2/provider.rb +69 -0
  76. data/lib/vagrant/plugin/v2/provisioner.rb +47 -0
  77. data/lib/vagrant/registry.rb +43 -17
  78. data/lib/vagrant/ssh.rb +15 -9
  79. data/lib/vagrant/ui.rb +7 -5
  80. data/lib/vagrant/util/is_port_open.rb +1 -1
  81. data/lib/vagrant/util/platform.rb +19 -0
  82. data/lib/vagrant/util/retryable.rb +8 -2
  83. data/lib/vagrant/util/safe_exec.rb +2 -2
  84. data/lib/vagrant/util/scoped_hash_override.rb +45 -0
  85. data/lib/vagrant/util/ssh.rb +126 -0
  86. data/lib/vagrant/util/string_block_editor.rb +75 -0
  87. data/lib/vagrant/util/subprocess.rb +33 -10
  88. data/lib/vagrant/util/which.rb +43 -0
  89. data/lib/vagrant/version.rb +1 -1
  90. data/plugins/README.md +5 -0
  91. data/plugins/commands/box/command/add.rb +46 -0
  92. data/plugins/commands/box/command/list.rb +41 -0
  93. data/plugins/commands/box/command/remove.rb +37 -0
  94. data/plugins/commands/box/command/repackage.rb +43 -0
  95. data/plugins/commands/box/command/root.rb +75 -0
  96. data/plugins/commands/box/plugin.rb +15 -0
  97. data/plugins/commands/destroy/command.rb +31 -0
  98. data/plugins/commands/destroy/plugin.rb +18 -0
  99. data/plugins/commands/halt/command.rb +33 -0
  100. data/plugins/commands/halt/plugin.rb +18 -0
  101. data/{lib/vagrant/command/init.rb → plugins/commands/init/command.rb} +4 -4
  102. data/plugins/commands/init/plugin.rb +18 -0
  103. data/plugins/commands/package/command.rb +83 -0
  104. data/plugins/commands/package/plugin.rb +18 -0
  105. data/plugins/commands/plugin/action.rb +52 -0
  106. data/plugins/commands/plugin/action/bundler_check.rb +25 -0
  107. data/plugins/commands/plugin/action/install_gem.rb +70 -0
  108. data/plugins/commands/plugin/action/license_plugin.rb +54 -0
  109. data/plugins/commands/plugin/action/list_plugins.rb +54 -0
  110. data/plugins/commands/plugin/action/prune_gems.rb +149 -0
  111. data/plugins/commands/plugin/action/uninstall_plugin.rb +23 -0
  112. data/plugins/commands/plugin/command/base.rb +22 -0
  113. data/plugins/commands/plugin/command/install.rb +39 -0
  114. data/plugins/commands/plugin/command/license.rb +31 -0
  115. data/plugins/commands/plugin/command/list.rb +28 -0
  116. data/plugins/commands/plugin/command/root.rb +75 -0
  117. data/plugins/commands/plugin/command/uninstall.rb +28 -0
  118. data/plugins/commands/plugin/gem_helper.rb +74 -0
  119. data/plugins/commands/plugin/plugin.rb +22 -0
  120. data/plugins/commands/plugin/state_file.rb +57 -0
  121. data/plugins/commands/provision/command.rb +34 -0
  122. data/plugins/commands/provision/plugin.rb +18 -0
  123. data/plugins/commands/reload/command.rb +37 -0
  124. data/plugins/commands/reload/plugin.rb +18 -0
  125. data/plugins/commands/resume/command.rb +25 -0
  126. data/plugins/commands/resume/plugin.rb +17 -0
  127. data/{lib/vagrant/command/ssh.rb → plugins/commands/ssh/command.rb} +17 -41
  128. data/plugins/commands/ssh/plugin.rb +17 -0
  129. data/{lib/vagrant/command/ssh_config.rb → plugins/commands/ssh_config/command.rb} +14 -16
  130. data/plugins/commands/ssh_config/plugin.rb +18 -0
  131. data/plugins/commands/status/command.rb +39 -0
  132. data/plugins/commands/status/plugin.rb +18 -0
  133. data/plugins/commands/suspend/command.rb +25 -0
  134. data/plugins/commands/suspend/plugin.rb +18 -0
  135. data/plugins/commands/up/command.rb +45 -0
  136. data/plugins/commands/up/plugin.rb +17 -0
  137. data/{lib/vagrant/command → plugins/commands/up}/start_mixins.rb +6 -6
  138. data/{lib/vagrant/communication/ssh.rb → plugins/communicators/ssh/communicator.rb} +139 -52
  139. data/plugins/communicators/ssh/plugin.rb +19 -0
  140. data/plugins/guests/arch/guest.rb +41 -0
  141. data/plugins/guests/arch/plugin.rb +15 -0
  142. data/{lib/vagrant/guest/debian.rb → plugins/guests/debian/guest.rb} +21 -13
  143. data/plugins/guests/debian/plugin.rb +15 -0
  144. data/{lib/vagrant/guest/fedora.rb → plugins/guests/fedora/guest.rb} +19 -14
  145. data/plugins/guests/fedora/plugin.rb +15 -0
  146. data/plugins/guests/freebsd/config.rb +13 -0
  147. data/plugins/guests/freebsd/guest.rb +70 -0
  148. data/plugins/guests/freebsd/plugin.rb +20 -0
  149. data/plugins/guests/gentoo/guest.rb +51 -0
  150. data/plugins/guests/gentoo/plugin.rb +15 -0
  151. data/plugins/guests/linux/config.rb +13 -0
  152. data/{lib/vagrant/guest/linux.rb → plugins/guests/linux/guest.rb} +35 -34
  153. data/plugins/guests/linux/plugin.rb +20 -0
  154. data/plugins/guests/openbsd/guest.rb +13 -0
  155. data/plugins/guests/openbsd/plugin.rb +15 -0
  156. data/{lib/vagrant/guest/redhat.rb → plugins/guests/redhat/guest.rb} +22 -15
  157. data/plugins/guests/redhat/plugin.rb +15 -0
  158. data/plugins/guests/solaris/config.rb +18 -0
  159. data/plugins/guests/solaris/guest.rb +73 -0
  160. data/plugins/guests/solaris/plugin.rb +20 -0
  161. data/plugins/guests/suse/guest.rb +24 -0
  162. data/plugins/guests/suse/plugin.rb +15 -0
  163. data/plugins/guests/ubuntu/guest.rb +44 -0
  164. data/plugins/guests/ubuntu/plugin.rb +15 -0
  165. data/{lib/vagrant/hosts/arch.rb → plugins/hosts/arch/host.rb} +18 -5
  166. data/plugins/hosts/arch/plugin.rb +15 -0
  167. data/{lib/vagrant/hosts/bsd.rb → plugins/hosts/bsd/host.rb} +16 -11
  168. data/plugins/hosts/bsd/plugin.rb +15 -0
  169. data/{lib/vagrant/hosts/fedora.rb → plugins/hosts/fedora/host.rb} +8 -4
  170. data/plugins/hosts/fedora/plugin.rb +15 -0
  171. data/{lib/vagrant/hosts/freebsd.rb → plugins/hosts/freebsd/host.rb} +10 -8
  172. data/plugins/hosts/freebsd/plugin.rb +15 -0
  173. data/{lib/vagrant/hosts/gentoo.rb → plugins/hosts/gentoo/host.rb} +7 -3
  174. data/plugins/hosts/gentoo/plugin.rb +15 -0
  175. data/{lib/vagrant/hosts/linux.rb → plugins/hosts/linux/host.rb} +12 -11
  176. data/plugins/hosts/linux/plugin.rb +15 -0
  177. data/{lib/vagrant/hosts/opensuse.rb → plugins/hosts/opensuse/host.rb} +8 -4
  178. data/plugins/hosts/opensuse/plugin.rb +15 -0
  179. data/{lib/vagrant/hosts/windows.rb → plugins/hosts/windows/host.rb} +5 -4
  180. data/plugins/hosts/windows/plugin.rb +15 -0
  181. data/plugins/kernel_v1/config/nfs.rb +20 -0
  182. data/plugins/kernel_v1/config/package.rb +17 -0
  183. data/plugins/kernel_v1/config/ssh.rb +46 -0
  184. data/plugins/kernel_v1/config/vagrant.rb +31 -0
  185. data/plugins/kernel_v1/config/vm.rb +184 -0
  186. data/plugins/kernel_v1/plugin.rb +44 -0
  187. data/plugins/kernel_v2/config/nfs.rb +10 -0
  188. data/plugins/kernel_v2/config/package.rb +9 -0
  189. data/plugins/kernel_v2/config/ssh.rb +35 -0
  190. data/plugins/kernel_v2/config/vagrant.rb +9 -0
  191. data/plugins/kernel_v2/config/vm.rb +314 -0
  192. data/plugins/kernel_v2/config/vm_provisioner.rb +40 -0
  193. data/plugins/kernel_v2/config/vm_subvm.rb +30 -0
  194. data/plugins/kernel_v2/plugin.rb +44 -0
  195. data/plugins/providers/virtualbox/action.rb +308 -0
  196. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/boot.rb +12 -16
  197. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/check_accessible.rb +5 -5
  198. data/plugins/providers/virtualbox/action/check_created.rb +21 -0
  199. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/check_guest_additions.rb +18 -11
  200. data/plugins/providers/virtualbox/action/check_running.rb +21 -0
  201. data/plugins/providers/virtualbox/action/check_virtualbox.rb +22 -0
  202. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/clean_machine_folder.rb +5 -5
  203. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/clear_forwarded_ports.rb +4 -4
  204. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/clear_network_interfaces.rb +4 -4
  205. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/clear_shared_folders.rb +4 -5
  206. data/plugins/providers/virtualbox/action/created.rb +20 -0
  207. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/customize.rb +7 -7
  208. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/destroy.rb +5 -5
  209. data/plugins/providers/virtualbox/action/destroy_confirm.rb +17 -0
  210. data/plugins/providers/virtualbox/action/destroy_unused_network_interfaces.rb +16 -0
  211. data/plugins/providers/virtualbox/action/discard_state.rb +20 -0
  212. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/export.rb +7 -7
  213. data/plugins/providers/virtualbox/action/forced_halt.rb +25 -0
  214. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/forward_ports.rb +29 -42
  215. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/import.rb +15 -12
  216. data/plugins/providers/virtualbox/action/is_paused.rb +20 -0
  217. data/plugins/providers/virtualbox/action/is_running.rb +20 -0
  218. data/plugins/providers/virtualbox/action/is_saved.rb +20 -0
  219. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/match_mac_address.rb +5 -5
  220. data/plugins/providers/virtualbox/action/message_not_created.rb +16 -0
  221. data/plugins/providers/virtualbox/action/message_not_running.rb +16 -0
  222. data/plugins/providers/virtualbox/action/message_will_not_destroy.rb +17 -0
  223. data/plugins/providers/virtualbox/action/network.rb +366 -0
  224. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/package.rb +4 -7
  225. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/package_vagrantfile.rb +5 -8
  226. data/plugins/providers/virtualbox/action/prepare_forwarded_port_collision_params.rb +35 -0
  227. data/plugins/providers/virtualbox/action/prepare_nfs_settings.rb +51 -0
  228. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/prune_nfs_exports.rb +5 -5
  229. data/plugins/providers/virtualbox/action/resume.rb +25 -0
  230. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/sane_defaults.rb +41 -32
  231. data/plugins/providers/virtualbox/action/set_name.rb +40 -0
  232. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/setup_package_files.rb +5 -8
  233. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/share_folders.rb +24 -25
  234. data/{lib/vagrant/action/vm → plugins/providers/virtualbox/action}/suspend.rb +5 -5
  235. data/plugins/providers/virtualbox/config.rb +82 -0
  236. data/plugins/providers/virtualbox/driver/base.rb +344 -0
  237. data/plugins/providers/virtualbox/driver/meta.rb +142 -0
  238. data/plugins/providers/virtualbox/driver/version_4_0.rb +485 -0
  239. data/plugins/providers/virtualbox/driver/version_4_1.rb +485 -0
  240. data/plugins/providers/virtualbox/driver/version_4_2.rb +475 -0
  241. data/plugins/providers/virtualbox/model/forwarded_port.rb +58 -0
  242. data/plugins/providers/virtualbox/plugin.rb +42 -0
  243. data/plugins/providers/virtualbox/provider.rb +92 -0
  244. data/plugins/providers/virtualbox/util/compile_forwarded_ports.rb +31 -0
  245. data/plugins/provisioners/chef/config/base.rb +65 -0
  246. data/plugins/provisioners/chef/config/chef_client.rb +39 -0
  247. data/plugins/provisioners/chef/config/chef_solo.rb +87 -0
  248. data/plugins/provisioners/chef/plugin.rb +33 -0
  249. data/plugins/provisioners/chef/provisioner/base.rb +91 -0
  250. data/plugins/provisioners/chef/provisioner/chef_client.rb +103 -0
  251. data/plugins/provisioners/chef/provisioner/chef_solo.rb +182 -0
  252. data/plugins/provisioners/puppet/config/puppet.rb +70 -0
  253. data/plugins/provisioners/puppet/config/puppet_server.rb +16 -0
  254. data/plugins/provisioners/puppet/plugin.rb +33 -0
  255. data/plugins/provisioners/puppet/provisioner/puppet.rb +110 -0
  256. data/plugins/provisioners/puppet/provisioner/puppet_server.rb +67 -0
  257. data/plugins/provisioners/shell/config.rb +46 -0
  258. data/plugins/provisioners/shell/plugin.rb +23 -0
  259. data/plugins/provisioners/shell/provisioner.rb +66 -0
  260. data/templates/commands/init/Vagrantfile.erb +33 -21
  261. data/templates/commands/ssh_config/config.erb +1 -0
  262. data/templates/config/messages.erb +14 -0
  263. data/templates/config/validation_failed.erb +3 -3
  264. data/templates/guests/arch/network_dhcp.erb +4 -7
  265. data/templates/guests/arch/network_static.erb +6 -7
  266. data/templates/guests/debian/network_dhcp.erb +5 -0
  267. data/templates/locales/en.yml +336 -100
  268. data/templates/rgloader.rb +9 -0
  269. data/test/acceptance/support/isolated_environment.rb +3 -2
  270. data/test/support/tempdir.rb +13 -4
  271. data/test/unit/base.rb +6 -0
  272. data/test/unit/support/dummy_provider.rb +16 -0
  273. data/test/unit/support/isolated_environment.rb +132 -0
  274. data/test/unit/support/shared/base_context.rb +74 -0
  275. data/test/unit/vagrant/action/builder_test.rb +88 -48
  276. data/test/unit/vagrant/action/builtin/call_test.rb +145 -0
  277. data/test/unit/vagrant/action/builtin/confirm_test.rb +36 -0
  278. data/test/unit/vagrant/action/builtin/env_set_test.rb +20 -0
  279. data/test/unit/vagrant/action/builtin/graceful_halt_test.rb +61 -0
  280. data/test/unit/vagrant/action/builtin/lock_test.rb +98 -0
  281. data/test/unit/vagrant/action/builtin/ssh_exec_test.rb +57 -0
  282. data/test/unit/vagrant/action/hook_test.rb +101 -0
  283. data/test/unit/vagrant/action/runner_test.rb +15 -9
  284. data/test/unit/vagrant/box_collection_test.rb +219 -38
  285. data/test/unit/vagrant/box_test.rb +94 -19
  286. data/test/unit/vagrant/cli_test.rb +27 -0
  287. data/test/unit/vagrant/config/loader_test.rb +154 -49
  288. data/test/unit/vagrant/config/v1/dummy_config_test.rb +24 -0
  289. data/test/unit/vagrant/config/v1/loader_test.rb +145 -0
  290. data/test/unit/vagrant/config/v1/root_test.rb +40 -0
  291. data/test/unit/vagrant/config/v2/dummy_config_test.rb +24 -0
  292. data/test/unit/vagrant/config/v2/loader_test.rb +151 -0
  293. data/test/unit/vagrant/config/v2/root_test.rb +97 -0
  294. data/test/unit/vagrant/config/v2/util_test.rb +21 -0
  295. data/test/unit/vagrant/config_test.rb +40 -1
  296. data/test/unit/vagrant/downloaders/base_test.rb +0 -4
  297. data/test/unit/vagrant/downloaders/file_test.rb +21 -9
  298. data/test/unit/vagrant/downloaders/http_test.rb +4 -0
  299. data/test/unit/vagrant/environment_test.rb +414 -63
  300. data/test/unit/vagrant/hosts_test.rb +10 -9
  301. data/test/unit/vagrant/machine_state_test.rb +26 -0
  302. data/test/unit/vagrant/machine_test.rb +418 -0
  303. data/test/unit/vagrant/{command/base_test.rb → plugin/v1/command_test.rb} +2 -9
  304. data/test/unit/vagrant/plugin/v1/communicator_test.rb +9 -0
  305. data/test/unit/vagrant/plugin/v1/config_test.rb +50 -0
  306. data/test/unit/vagrant/plugin/v1/host_test.rb +5 -0
  307. data/test/unit/vagrant/plugin/v1/manager_test.rb +114 -0
  308. data/test/unit/vagrant/plugin/v1/plugin_test.rb +267 -0
  309. data/test/unit/vagrant/plugin/v1/provider_test.rb +18 -0
  310. data/test/unit/vagrant/plugin/v2/command_test.rb +238 -0
  311. data/test/unit/vagrant/plugin/v2/communicator_test.rb +9 -0
  312. data/test/unit/vagrant/plugin/v2/components_test.rb +17 -0
  313. data/test/unit/vagrant/plugin/v2/config_test.rb +60 -0
  314. data/test/unit/vagrant/plugin/v2/host_test.rb +5 -0
  315. data/test/unit/vagrant/plugin/v2/manager_test.rb +157 -0
  316. data/test/unit/vagrant/plugin/v2/plugin_test.rb +287 -0
  317. data/test/unit/vagrant/plugin/v2/provider_test.rb +18 -0
  318. data/test/unit/vagrant/registry_test.rb +59 -5
  319. data/test/unit/vagrant/util/scoped_hash_override_test.rb +48 -0
  320. data/test/unit/vagrant/util/ssh_test.rb +30 -0
  321. data/test/unit/vagrant/util/string_block_editor_test.rb +98 -0
  322. data/test/unit/vagrant/util/which_test.rb +43 -0
  323. data/test/unit/vagrant_test.rb +42 -13
  324. data/vagrant.gemspec +6 -7
  325. data/vagrant.gemspecbak +6 -7
  326. metadata +273 -358
  327. data/lib/vagrant/action/box/destroy.rb +0 -25
  328. data/lib/vagrant/action/box/download.rb +0 -84
  329. data/lib/vagrant/action/box/package.rb +0 -19
  330. data/lib/vagrant/action/box/unpackage.rb +0 -61
  331. data/lib/vagrant/action/box/verify.rb +0 -23
  332. data/lib/vagrant/action/builtin.rb +0 -171
  333. data/lib/vagrant/action/env/set.rb +0 -21
  334. data/lib/vagrant/action/environment.rb +0 -12
  335. data/lib/vagrant/action/general/check_virtualbox.rb +0 -28
  336. data/lib/vagrant/action/general/validate.rb +0 -18
  337. data/lib/vagrant/action/vm/check_box.rb +0 -33
  338. data/lib/vagrant/action/vm/check_port_collisions.rb +0 -89
  339. data/lib/vagrant/action/vm/default_name.rb +0 -22
  340. data/lib/vagrant/action/vm/destroy_unused_network_interfaces.rb +0 -20
  341. data/lib/vagrant/action/vm/discard_state.rb +0 -22
  342. data/lib/vagrant/action/vm/halt.rb +0 -32
  343. data/lib/vagrant/action/vm/host_name.rb +0 -21
  344. data/lib/vagrant/action/vm/network.rb +0 -403
  345. data/lib/vagrant/action/vm/nfs.rb +0 -196
  346. data/lib/vagrant/action/vm/provision.rb +0 -61
  347. data/lib/vagrant/action/vm/provisioner_cleanup.rb +0 -26
  348. data/lib/vagrant/action/vm/resume.rb +0 -20
  349. data/lib/vagrant/command.rb +0 -24
  350. data/lib/vagrant/command/base.rb +0 -167
  351. data/lib/vagrant/command/box.rb +0 -58
  352. data/lib/vagrant/command/box_add.rb +0 -37
  353. data/lib/vagrant/command/box_list.rb +0 -28
  354. data/lib/vagrant/command/box_remove.rb +0 -27
  355. data/lib/vagrant/command/box_repackage.rb +0 -27
  356. data/lib/vagrant/command/destroy.rb +0 -64
  357. data/lib/vagrant/command/gem.rb +0 -39
  358. data/lib/vagrant/command/halt.rb +0 -39
  359. data/lib/vagrant/command/package.rb +0 -75
  360. data/lib/vagrant/command/provision.rb +0 -40
  361. data/lib/vagrant/command/reload.rb +0 -39
  362. data/lib/vagrant/command/resume.rb +0 -33
  363. data/lib/vagrant/command/status.rb +0 -36
  364. data/lib/vagrant/command/suspend.rb +0 -33
  365. data/lib/vagrant/command/up.rb +0 -40
  366. data/lib/vagrant/communication.rb +0 -7
  367. data/lib/vagrant/communication/base.rb +0 -56
  368. data/lib/vagrant/config/base.rb +0 -82
  369. data/lib/vagrant/config/error_recorder.rb +0 -19
  370. data/lib/vagrant/config/nfs.rb +0 -8
  371. data/lib/vagrant/config/package.rb +0 -7
  372. data/lib/vagrant/config/ssh.rb +0 -27
  373. data/lib/vagrant/config/top.rb +0 -72
  374. data/lib/vagrant/config/vagrant.rb +0 -14
  375. data/lib/vagrant/config/vm.rb +0 -168
  376. data/lib/vagrant/config/vm/provisioner.rb +0 -52
  377. data/lib/vagrant/config/vm/sub_vm.rb +0 -17
  378. data/lib/vagrant/data_store.rb +0 -92
  379. data/lib/vagrant/driver.rb +0 -8
  380. data/lib/vagrant/driver/virtualbox.rb +0 -134
  381. data/lib/vagrant/driver/virtualbox_4_0.rb +0 -459
  382. data/lib/vagrant/driver/virtualbox_4_1.rb +0 -459
  383. data/lib/vagrant/driver/virtualbox_4_2.rb +0 -606
  384. data/lib/vagrant/driver/virtualbox_base.rb +0 -326
  385. data/lib/vagrant/guest.rb +0 -18
  386. data/lib/vagrant/guest/arch.rb +0 -56
  387. data/lib/vagrant/guest/base.rb +0 -99
  388. data/lib/vagrant/guest/freebsd.rb +0 -86
  389. data/lib/vagrant/guest/gentoo.rb +0 -46
  390. data/lib/vagrant/guest/linux/config.rb +0 -19
  391. data/lib/vagrant/guest/linux/error.rb +0 -9
  392. data/lib/vagrant/guest/openbsd.rb +0 -20
  393. data/lib/vagrant/guest/solaris.rb +0 -118
  394. data/lib/vagrant/guest/suse.rb +0 -17
  395. data/lib/vagrant/guest/ubuntu.rb +0 -23
  396. data/lib/vagrant/hosts/base.rb +0 -66
  397. data/lib/vagrant/provisioners.rb +0 -12
  398. data/lib/vagrant/provisioners/base.rb +0 -44
  399. data/lib/vagrant/provisioners/chef.rb +0 -168
  400. data/lib/vagrant/provisioners/chef_client.rb +0 -132
  401. data/lib/vagrant/provisioners/chef_solo.rb +0 -234
  402. data/lib/vagrant/provisioners/puppet.rb +0 -176
  403. data/lib/vagrant/provisioners/puppet_server.rb +0 -78
  404. data/lib/vagrant/provisioners/shell.rb +0 -103
  405. data/lib/vagrant/vm.rb +0 -195
  406. data/test/buildbot/README.md +0 -72
  407. data/test/buildbot/buildbot_config/__init__.py +0 -0
  408. data/test/buildbot/buildbot_config/config/__init__.py +0 -0
  409. data/test/buildbot/buildbot_config/config/loader.py +0 -24
  410. data/test/buildbot/buildbot_config/config/master.py +0 -24
  411. data/test/buildbot/buildbot_config/config/slave.py +0 -22
  412. data/test/buildbot/buildbot_config/master/__init__.py +0 -6
  413. data/test/buildbot/buildbot_config/master/builders.py +0 -78
  414. data/test/buildbot/buildbot_config/master/buildsteps.py +0 -100
  415. data/test/buildbot/buildbot_config/master/change_sources.py +0 -8
  416. data/test/buildbot/buildbot_config/master/schedulers.py +0 -32
  417. data/test/buildbot/buildbot_config/master/slaves.py +0 -60
  418. data/test/buildbot/buildbot_config/master/status.py +0 -52
  419. data/test/buildbot/master/Makefile.sample +0 -28
  420. data/test/buildbot/master/buildbot.tac +0 -36
  421. data/test/buildbot/master/master.cfg +0 -67
  422. data/test/buildbot/master/public_html/bg_gradient.jpg +0 -0
  423. data/test/buildbot/master/public_html/default.css +0 -545
  424. data/test/buildbot/master/public_html/favicon.ico +0 -0
  425. data/test/buildbot/master/public_html/robots.txt +0 -10
  426. data/test/buildbot/master/public_html/static/css/bootstrap-1.4.0.min.css +0 -356
  427. data/test/buildbot/master/public_html/static/css/prettify.css +0 -97
  428. data/test/buildbot/master/public_html/static/css/syntax.css +0 -60
  429. data/test/buildbot/master/public_html/static/css/vagrant.base.css +0 -205
  430. data/test/buildbot/master/public_html/static/images/base_box_mac.jpg +0 -0
  431. data/test/buildbot/master/public_html/static/images/getting-started/success.jpg +0 -0
  432. data/test/buildbot/master/public_html/static/images/icons/error.png +0 -0
  433. data/test/buildbot/master/public_html/static/images/vagrant_chilling.png +0 -0
  434. data/test/buildbot/master/public_html/static/images/vagrant_holding.png +0 -0
  435. data/test/buildbot/master/public_html/static/images/vagrant_looking.png +0 -0
  436. data/test/buildbot/master/public_html/static/images/windows/alter_path.jpg +0 -0
  437. data/test/buildbot/master/public_html/static/images/windows/edit_path.jpg +0 -0
  438. data/test/buildbot/master/public_html/static/images/windows/environment_variables_button.jpg +0 -0
  439. data/test/buildbot/master/public_html/static/images/windows/port_and_ppk_path.jpg +0 -0
  440. data/test/buildbot/master/public_html/static/images/windows/ppk_selection.jpg +0 -0
  441. data/test/buildbot/master/public_html/static/images/windows/putty_first_screen.jpg +0 -0
  442. data/test/buildbot/master/public_html/static/images/windows/save_result.jpg +0 -0
  443. data/test/buildbot/master/public_html/static/images/windows/vbox_manage_default_location.jpg +0 -0
  444. data/test/buildbot/master/public_html/static/js/bootstrap-tabs.js +0 -80
  445. data/test/buildbot/master/public_html/static/js/jquery-1.7.min.js +0 -4
  446. data/test/buildbot/master/templates/authfail.html +0 -9
  447. data/test/buildbot/master/templates/build.html +0 -205
  448. data/test/buildbot/master/templates/builder.html +0 -118
  449. data/test/buildbot/master/templates/builders.html +0 -33
  450. data/test/buildbot/master/templates/buildslave.html +0 -72
  451. data/test/buildbot/master/templates/buildslaves.html +0 -70
  452. data/test/buildbot/master/templates/change.html +0 -15
  453. data/test/buildbot/master/templates/layouts/base.html +0 -58
  454. data/test/buildbot/master/templates/macros/box.html +0 -37
  455. data/test/buildbot/master/templates/macros/build_line.html +0 -50
  456. data/test/buildbot/master/templates/macros/change.html +0 -81
  457. data/test/buildbot/master/templates/macros/forms.html +0 -300
  458. data/test/buildbot/master/templates/root.html +0 -42
  459. data/test/buildbot/master/templates/waterfall.html +0 -53
  460. data/test/buildbot/requirements.txt +0 -4
  461. data/test/buildbot/scripts/deploy.sh +0 -38
  462. data/test/buildbot/scripts/setup.sh +0 -107
  463. data/test/buildbot/slave/buildbot.tac +0 -43
  464. data/test/buildbot/slave/info/admin +0 -1
  465. data/test/buildbot/slave/info/host +0 -1
  466. data/test/buildbot/tests/__init__.py +0 -0
  467. data/test/buildbot/tests/master/__init__.py +0 -0
  468. data/test/buildbot/tests/master/test_slaves.py +0 -41
  469. data/test/buildbot/vendor/choices-0.4.0.tar.gz +0 -0
  470. data/test/unit/vagrant/action/environment_test.rb +0 -16
  471. data/test/unit/vagrant/config/base_test.rb +0 -48
  472. data/test/unit/vagrant/config/ssh_test.rb +0 -17
  473. data/test/unit/vagrant/config/top_test.rb +0 -69
  474. data/test/unit/vagrant/config/vm_test.rb +0 -71
  475. data/test/unit/vagrant/data_store_test.rb +0 -79
  476. data/test/unit_legacy/locales/en.yml +0 -8
  477. data/test/unit_legacy/test_helper.rb +0 -32
  478. data/test/unit_legacy/vagrant/action/box/destroy_test.rb +0 -18
  479. data/test/unit_legacy/vagrant/action/box/download_test.rb +0 -125
  480. data/test/unit_legacy/vagrant/action/box/package_test.rb +0 -25
  481. data/test/unit_legacy/vagrant/action/box/unpackage_test.rb +0 -84
  482. data/test/unit_legacy/vagrant/action/box/verify_test.rb +0 -30
  483. data/test/unit_legacy/vagrant/action/env/set_test.rb +0 -24
  484. data/test/unit_legacy/vagrant/action/general/package_test.rb +0 -268
  485. data/test/unit_legacy/vagrant/action/general/validate_test.rb +0 -31
  486. data/test/unit_legacy/vagrant/action/vm/boot_test.rb +0 -66
  487. data/test/unit_legacy/vagrant/action/vm/check_accessible_test.rb +0 -61
  488. data/test/unit_legacy/vagrant/action/vm/check_box_test.rb +0 -61
  489. data/test/unit_legacy/vagrant/action/vm/check_guest_additions_test.rb +0 -9
  490. data/test/unit_legacy/vagrant/action/vm/clean_machine_folder_test.rb +0 -84
  491. data/test/unit_legacy/vagrant/action/vm/clear_forwarded_ports_test.rb +0 -52
  492. data/test/unit_legacy/vagrant/action/vm/clear_nfs_exports_test.rb +0 -22
  493. data/test/unit_legacy/vagrant/action/vm/clear_shared_folders_test.rb +0 -40
  494. data/test/unit_legacy/vagrant/action/vm/customize_test.rb +0 -37
  495. data/test/unit_legacy/vagrant/action/vm/destroy_test.rb +0 -25
  496. data/test/unit_legacy/vagrant/action/vm/destroy_unused_network_interfaces_test.rb +0 -49
  497. data/test/unit_legacy/vagrant/action/vm/discard_state_test.rb +0 -45
  498. data/test/unit_legacy/vagrant/action/vm/export_test.rb +0 -107
  499. data/test/unit_legacy/vagrant/action/vm/forward_ports_helpers_test.rb +0 -77
  500. data/test/unit_legacy/vagrant/action/vm/forward_ports_test.rb +0 -197
  501. data/test/unit_legacy/vagrant/action/vm/halt_test.rb +0 -79
  502. data/test/unit_legacy/vagrant/action/vm/host_name_test.rb +0 -36
  503. data/test/unit_legacy/vagrant/action/vm/import_test.rb +0 -66
  504. data/test/unit_legacy/vagrant/action/vm/match_mac_address_test.rb +0 -40
  505. data/test/unit_legacy/vagrant/action/vm/modify_test.rb +0 -38
  506. data/test/unit_legacy/vagrant/action/vm/network_test.rb +0 -286
  507. data/test/unit_legacy/vagrant/action/vm/nfs_helpers_test.rb +0 -26
  508. data/test/unit_legacy/vagrant/action/vm/nfs_test.rb +0 -260
  509. data/test/unit_legacy/vagrant/action/vm/package_test.rb +0 -25
  510. data/test/unit_legacy/vagrant/action/vm/package_vagrantfile_test.rb +0 -46
  511. data/test/unit_legacy/vagrant/action/vm/provision_test.rb +0 -65
  512. data/test/unit_legacy/vagrant/action/vm/provisioner_cleanup_test.rb +0 -56
  513. data/test/unit_legacy/vagrant/action/vm/resume_test.rb +0 -35
  514. data/test/unit_legacy/vagrant/action/vm/share_folders_test.rb +0 -144
  515. data/test/unit_legacy/vagrant/action/vm/suspend_test.rb +0 -35
  516. data/test/unit_legacy/vagrant/action_test.rb +0 -89
  517. data/test/unit_legacy/vagrant/box_collection_test.rb +0 -45
  518. data/test/unit_legacy/vagrant/box_test.rb +0 -74
  519. data/test/unit_legacy/vagrant/cli_test.rb +0 -35
  520. data/test/unit_legacy/vagrant/command/base_test.rb +0 -23
  521. data/test/unit_legacy/vagrant/command/group_base_test.rb +0 -15
  522. data/test/unit_legacy/vagrant/command/helpers_test.rb +0 -88
  523. data/test/unit_legacy/vagrant/command/init_test.rb +0 -10
  524. data/test/unit_legacy/vagrant/command/package_test.rb +0 -27
  525. data/test/unit_legacy/vagrant/config/base_test.rb +0 -52
  526. data/test/unit_legacy/vagrant/config/error_recorder_test.rb +0 -18
  527. data/test/unit_legacy/vagrant/config/ssh_test.rb +0 -12
  528. data/test/unit_legacy/vagrant/config/vagrant_test.rb +0 -35
  529. data/test/unit_legacy/vagrant/config/vm/provisioner_test.rb +0 -92
  530. data/test/unit_legacy/vagrant/config/vm_test.rb +0 -47
  531. data/test/unit_legacy/vagrant/config_test.rb +0 -148
  532. data/test/unit_legacy/vagrant/downloaders/http_test.rb +0 -93
  533. data/test/unit_legacy/vagrant/environment_test.rb +0 -539
  534. data/test/unit_legacy/vagrant/errors_test.rb +0 -42
  535. data/test/unit_legacy/vagrant/hosts/base_test.rb +0 -46
  536. data/test/unit_legacy/vagrant/hosts/bsd_test.rb +0 -53
  537. data/test/unit_legacy/vagrant/hosts/linux_test.rb +0 -54
  538. data/test/unit_legacy/vagrant/plugin_test.rb +0 -9
  539. data/test/unit_legacy/vagrant/provisioners/base_test.rb +0 -63
  540. data/test/unit_legacy/vagrant/provisioners/chef_client_test.rb +0 -190
  541. data/test/unit_legacy/vagrant/provisioners/chef_solo_test.rb +0 -115
  542. data/test/unit_legacy/vagrant/provisioners/chef_test.rb +0 -209
  543. data/test/unit_legacy/vagrant/provisioners/puppet_server_test.rb +0 -68
  544. data/test/unit_legacy/vagrant/provisioners/puppet_test.rb +0 -182
  545. data/test/unit_legacy/vagrant/provisioners/shell_test.rb +0 -79
  546. data/test/unit_legacy/vagrant/ssh/session_test.rb +0 -40
  547. data/test/unit_legacy/vagrant/ssh_test.rb +0 -304
  548. data/test/unit_legacy/vagrant/systems/base_test.rb +0 -18
  549. data/test/unit_legacy/vagrant/systems/linux_test.rb +0 -104
  550. data/test/unit_legacy/vagrant/util/busy_test.rb +0 -106
  551. data/test/unit_legacy/vagrant/util/counter_test.rb +0 -29
  552. data/test/unit_legacy/vagrant/util/platform_test.rb +0 -18
  553. data/test/unit_legacy/vagrant/util/stacked_proc_runner_test.rb +0 -43
  554. data/test/unit_legacy/vagrant/util/template_renderer_test.rb +0 -145
  555. data/test/unit_legacy/vagrant/vm_test.rb +0 -300
  556. data/vagrant-1.1.4.gem +0 -0
  557. data/vagrantup-0.1.0.gem +0 -0
  558. data/vagrantup-0.1.1.gem +0 -0
  559. data/vagrantup-0.1.2.gem +0 -0
  560. data/vagrantup-0.1.3.gem +0 -0
  561. data/vagrantup-0.1.4.gem +0 -0
  562. data/vagrantup-0.2.0.gem +0 -0
  563. data/vagrantup-0.3.0.gem +0 -0
  564. data/vagrantup-0.3.1.gem +0 -0
  565. data/vagrantup-0.3.2.gem +0 -0
  566. data/vagrantup-0.3.3.gem +0 -0
  567. data/vagrantup-0.3.4.gem +0 -0
  568. data/vagrantup-0.4.0.gem +0 -0
  569. data/vagrantup-0.4.1.gem +0 -0
  570. data/vagrantup-0.4.3.dev.gem +0 -0
  571. data/vagrantup-0.5.0.gem +0 -0
  572. data/vagrantup-0.5.1.gem +0 -0
  573. data/vagrantup-0.5.2.gem +0 -0
  574. data/vagrantup-0.5.3.gem +0 -0
  575. data/vagrantup-0.5.4.gem +0 -0
  576. data/vagrantup-0.6.0.gem +0 -0
  577. data/vagrantup-0.6.1.gem +0 -0
  578. data/vagrantup-0.6.2.gem +0 -0
  579. data/vagrantup-0.6.3.gem +0 -0
  580. data/vagrantup-0.6.4.gem +0 -0
  581. data/vagrantup-0.6.5.gem +0 -0
  582. data/vagrantup-0.6.6.gem +0 -0
  583. data/vagrantup-0.6.7.gem +0 -0
  584. data/vagrantup-0.6.8.gem +0 -0
  585. data/vagrantup-0.6.9.gem +0 -0
  586. data/vagrantup-0.7.0.gem +0 -0
  587. data/vagrantup-0.7.1.gem +0 -0
  588. data/vagrantup-0.7.2.gem +0 -0
  589. data/vagrantup-0.7.3.gem +0 -0
  590. data/vagrantup-0.7.4.gem +0 -0
  591. data/vagrantup-0.7.5.gem +0 -0
  592. data/vagrantup-0.7.6.gem +0 -0
  593. data/vagrantup-0.7.7.gem +0 -0
  594. data/vagrantup-0.7.8.gem +0 -0
  595. data/vagrantup-0.8.0.gem +0 -0
  596. data/vagrantup-0.8.1.gem +0 -0
  597. data/vagrantup-0.8.10.gem +0 -0
  598. data/vagrantup-0.8.2.gem +0 -0
  599. data/vagrantup-0.8.3.gem +0 -0
  600. data/vagrantup-0.8.4.gem +0 -0
  601. data/vagrantup-0.8.5.gem +0 -0
  602. data/vagrantup-0.8.6.gem +0 -0
  603. data/vagrantup-0.8.7.gem +0 -0
  604. data/vagrantup-0.8.8.gem +0 -0
  605. data/vagrantup-0.8.9.gem +0 -0
  606. data/vagrantup-0.9.0.gem +0 -0
  607. data/vagrantup-0.9.1.gem +0 -0
  608. data/vagrantup-0.9.2.gem +0 -0
  609. data/vagrantup-0.9.3.gem +0 -0
  610. data/vagrantup-0.9.4.gem +0 -0
  611. data/vagrantup-0.9.5.gem +0 -0
  612. data/vagrantup-0.9.6.gem +0 -0
  613. data/vagrantup-0.9.7.gem +0 -0
  614. data/vagrantup-0.9.99.1.gem +0 -0
  615. data/vagrantup-0.9.99.2.gem +0 -0
  616. data/vagrantup-1.0.0.gem +0 -0
  617. data/vagrantup-1.0.1.gem +0 -0
  618. data/vagrantup-1.0.2.gem +0 -0
  619. data/vagrantup-1.0.3.gem +0 -0
  620. data/vagrantup-1.0.4.gem +0 -0
  621. data/vagrantup-1.0.5.gem +0 -0
  622. data/vagrantup-1.0.6.gem +0 -0
  623. data/vagrantup-1.1.4.gem +0 -0
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: af5a4fbac1196e53c4539fa34d8680793d789245
4
- data.tar.gz: 2c8ac719a48f962be8604775953f745003cad31a
3
+ metadata.gz: 5792b5a7710c5518a4358d532a1746f69e612bd6
4
+ data.tar.gz: cb084ce778ebfd587cb8d034d1dccde6e2fc71b6
5
5
  SHA512:
6
- metadata.gz: 1cc988d087d62e496054eccba11ce65ec7fe9f8dbce697ee83eafd0634d1f60ffb44863ac1210dd6a0012c6d78306896fc7d96a5c0bd17cc7a926da5068617c8
7
- data.tar.gz: 66ac85e05e6c84c2cbf8413b4495b5502578bc736f244a2862f1601b1c1770a70b0c4bae75d19aed2c62efc5e28bcb19860cd28da2dc19677d949bcf0dbeae78
6
+ metadata.gz: a53f20097b36bbb85ac603e5ed8eb3a33ab03ff1f8ce1e505ffe096d7316d36f46eedd22e0e7a08c1cab6c3a24155ef20efcc84bb5da12be7ce7b77711ed8c3b
7
+ data.tar.gz: 82d177f84a3c71102b174f7a88d890e7e2a57ae93a0aa01163fda1923be2a7a1a439e398bf9c87b5d17adf5491009e35e6972238f5028c85e6ed7a837ea7f18b
@@ -1,3 +1,94 @@
1
+ ## 1.1.0 (March 14, 2013)
2
+
3
+ BACKWARDS INCOMPATIBILITIES:
4
+
5
+ - Vagrantfiles from 1.0.x that _do not use_ any plugins are fully
6
+ backwards compatible. If plugins are used, they must be removed prior
7
+ to upgrading. The new plugin system in place will avoid this issue in
8
+ the future.
9
+ - Lots of changes introduced in the form of a new configuration version and
10
+ format, but this is _opt-in_. Old Vagrantfile format continues to be supported,
11
+ as promised. To use the new features that will be introduced throughout
12
+ the 1.x series, you'll have to upgrade at some point.
13
+
14
+ FEATURES:
15
+
16
+ - Groundwork for **providers**, alternate backends for Vagrant that
17
+ allow Vagrant to power systems other than VirtualBox. Much improvement
18
+ and change will come to this throughout the 1.x lifecycle. The API
19
+ will continue to change, features will be added, and more. Specifically,
20
+ a revamped system for handling shared folders gracefully across providers
21
+ will be introduced in a future release.
22
+ - New plugin system which adds much more structure and stability to
23
+ the overall API. The goal of this system is to make it easier to write
24
+ powerful plugins for Vagrant while providing a backwards-compatible API
25
+ so that plugins will always _load_ (though they will almost certainly
26
+ not be _functional_ in future versions of Vagrant).
27
+ - Plugins are now installed and managed using the `vagrant plugin` interface.
28
+ - Allow "file://" URLs for box URLs. [GH-1087]
29
+ - Emit "vagrant-mount" upstart event when NFS shares are mounted. [GH-1118]
30
+ - Add a VirtualBox provider config `auto_nat_dns_proxy` which when set to
31
+ false will not attempt to automatically manage NAT DNS proxy settings
32
+ with VirtualBox. [GH-1313]
33
+ - `vagrant provision` accepts the `--provision-with` flag [GH-1167]
34
+ - Set the name of VirtualBox machines with `virtualbox.name` in the
35
+ VirtualBox provider config. [GH-1126]
36
+ - `vagrant ssh` will execute an `ssh` binary on Windows if it is on
37
+ your PATH. [GH-933]
38
+ - The environmental variable `VAGRANT_VAGRANTFILE` can be used to
39
+ specify an alternate Vagrantfile filename.
40
+
41
+ IMPROVEMENTS / BUG FIXES:
42
+
43
+ - Vagrant works much better in Cygwin environments on Windows by
44
+ properly resolving Cygwin paths. [GH-1366]
45
+ - Improve the SSH "ready?" check by more gracefully handling timeouts. [GH-841]
46
+ - Human friendly error if connection times out for HTTP downloads. [GH-849]
47
+ - Detect when the VirtualBox installation is incomplete and error. [GH-846]
48
+ - Detect when kernel modules for VirtualBox need to be installed on Gentoo
49
+ systems and report a user-friendly error. [GH-710]
50
+ - All `vagrant` commands that can take a target VM name can take one even
51
+ if you're not in a multi-VM environment. [GH-894]
52
+ - Hostname is set before networks are setup to avoid very slow `sudo`
53
+ speeds on CentOS. [GH-922]
54
+ - `config.ssh.shell` now includes the flags to pass to it, such as `-l` [GH-917]
55
+ - The check for whether a port is open or not is more complete by
56
+ catching ENETUNREACH errors. [GH-948]
57
+ - SSH uses LogLevel FATAL so that errors are still shown.
58
+ - Sending a SIGINT (Ctrl-C) very early on when executing `vagrant` no
59
+ longer results in an ugly stack trace.
60
+ - Chef JSON configuration output is now pretty-printed to be
61
+ human readable. [GH-1146]
62
+ that SSHing succeeds when booting a machine.
63
+ - VMs in the "guru meditation" state can be destroyed now using
64
+ `vagrant destroy`.
65
+ - Fix issue where changing SSH key permissions didn't properly work. [GH-911]
66
+ - Fix issue where Vagrant didn't properly detect VBoxManage on Windows
67
+ if VBOX_INSTALL_PATH contained multiple paths. [GH-885]
68
+ - Fix typo in setting host name for Gentoo guests. [GH-931]
69
+ - Files that are included with `vagrant package --include` now properly
70
+ preserve file attributes on earlier versions of Ruby. [GH-951]
71
+ - Multiple interfaces now work with Arch linux guests. [GH-957]
72
+ - Fix issue where subprocess execution would always spin CPU of Ruby
73
+ process to 100%. [GH-832]
74
+ - Fix issue where shell provisioner would sometimes never end. [GH-968]
75
+ - Fix issue where puppet would reorder module paths. [GH-964]
76
+ - When console input is asked for (destroying a VM, bridged interfaces, etc.),
77
+ keystrokes such as ctrl-D and ctrl-C are more gracefully handled. [GH-1017]
78
+ - Fixed bug where port check would use "localhost" on systems where
79
+ "localhost" is not available. [GH-1057]
80
+ - Add missing translation for "saving" state on VirtualBox. [GH-1110]
81
+ - Proper error message if the remote end unexpectedly resets the connection
82
+ while downloading a box over HTTP. [GH-1090]
83
+ - Human-friendly error is raised if there are permission issues when
84
+ using SCP to upload files. [GH-924]
85
+ - Box adding doesn't use `/tmp` anymore which can avoid some cross-device
86
+ copy issues. [GH-1199]
87
+ - Vagrant works properly in folders with strange characters. [GH-1223]
88
+ - Vagrant properly handles "paused" VirtualBox machines. [GH-1184]
89
+ - Better behavior around permissions issues when copying insecure
90
+ private key. [GH-580]
91
+
1
92
  ## 1.0.7 (March 13, 2013)
2
93
 
3
94
  - Detect if a newer version of Vagrant ran and error if it did,
data/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  The MIT License
2
2
 
3
- Copyright (c) 2010-2012Mitchell Hashimoto and John Bender
3
+ Copyright (c) 2010-2013 Mitchell Hashimoto
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
@@ -18,4 +18,4 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
18
  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
19
  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
20
  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
- THE SOFTWARE.
21
+ THE SOFTWARE.
data/README.md CHANGED
@@ -1,38 +1,36 @@
1
1
  # Vagrant
2
2
 
3
- * Website: [http://vagrantup.com](http://vagrantup.com)
3
+ * Website: [http://www.vagrantup.com](http://www.vagrantup.com)
4
4
  * Source: [https://github.com/mitchellh/vagrant](https://github.com/mitchellh/vagrant)
5
5
  * IRC: `#vagrant` on Freenode
6
6
  * Mailing list: [Google Groups](http://groups.google.com/group/vagrant-up)
7
7
 
8
- Vagrant is a tool for building and distributing virtualized development environments.
8
+ Vagrant is a tool for building and distributing development environments.
9
9
 
10
- By providing automated creation and provisioning of virtual machines using [Oracle’s VirtualBox](http://www.virtualbox.org),
11
- Vagrant provides the tools to create and configure lightweight, reproducible, and portable
12
- virtual environments. For more information, see the part of the getting started guide
13
- on “[Why Vagrant?](http://vagrantup.com/docs/getting-started/why.html)”
10
+ Vagrant provides the framework and configuration format to create and
11
+ manage complete portable development environments. These development
12
+ environments can live on your computer or in the cloud, and are portable
13
+ between Windows, Mac OS X, and Linux.
14
14
 
15
15
  ## Quick Start
16
16
 
17
17
  First, make sure your development machine has [VirtualBox](http://www.virtualbox.org)
18
- installed. The setup from that point forward is very easy, since Vagrant is simply
19
- a rubygem.
20
-
21
- gem install vagrant
18
+ installed. After this, [download and install the appropriate Vagrant package for your OS](http://downloads.vagrantup.com). If you're not on Mac OS X or Windows, you'll need
19
+ to add `/opt/vagrant/bin` to your `PATH`. After this, you're ready to go!
22
20
 
23
21
  To build your first virtual environment:
24
22
 
25
- vagrant init lucid32 http://files.vagrantup.com/lucid32.box
23
+ vagrant init precise32 http://files.vagrantup.com/precise32.box
26
24
  vagrant up
27
25
 
28
26
  Note: The above `vagrant up` command will also trigger Vagrant to download the
29
- `lucid32` box via the specified URL. Vagrant only does this if it detects that
27
+ `precise32` box via the specified URL. Vagrant only does this if it detects that
30
28
  the box doesn't already exist on your system.
31
29
 
32
30
  ## Getting Started Guide
33
31
 
34
32
  To learn how to build a fully functional rails development environment, view the
35
- [getting started guide](http://vagrantup.com/docs/getting-started/index.html).
33
+ [getting started guide](http://vagrantup.com/v1/docs/getting-started/index.html).
36
34
 
37
35
  ## Installing the Gem from Git
38
36
 
@@ -1,4 +1,10 @@
1
1
  #!/usr/bin/env ruby
2
+
3
+ # Trap interrupts to quit cleanly. This will be overriden at some point
4
+ # by Vagrant. This is made to catch any interrupts while Vagrant is
5
+ # initializing which have historically resulted in stack traces.
6
+ Signal.trap("INT") { exit 1 }
7
+
2
8
  require 'log4r'
3
9
  require 'vagrant'
4
10
  require 'vagrant/cli'
@@ -28,6 +34,17 @@ else
28
34
  opts[:ui_class] = Vagrant::UI::Colored
29
35
  end
30
36
 
37
+ # This is kind of hacky, and I'd love to find a better way to do this, but
38
+ # if we're accessing the plugin interface, we want to NOT load plugins
39
+ # for this run, because they can actually interfere with the function
40
+ # of the plugin interface.
41
+ ARGV.each do |arg|
42
+ if !arg.start_with?("-")
43
+ ENV["VAGRANT_NO_PLUGINS"] = "1" if arg == "plugin"
44
+ break
45
+ end
46
+ end
47
+
31
48
  env = nil
32
49
  begin
33
50
  # Create the environment, which is the cwd of wherever the
@@ -35,12 +52,19 @@ begin
35
52
  logger.debug("Creating Vagrant environment")
36
53
  env = Vagrant::Environment.new(opts)
37
54
 
38
- # Load the environment
39
- logger.debug("Loading environment")
40
- env.load!
55
+ # If we're not in the installer, warn.
56
+ env.ui.warn(I18n.t("vagrant.general.not_in_installer")) if !Vagrant.in_installer?
57
+
58
+ begin
59
+ # Execute the CLI interface, and exit with the proper error code
60
+ exit_status = env.cli(ARGV)
61
+ ensure
62
+ # Unload the environment so cleanup can be done
63
+ env.unload
64
+ end
41
65
 
42
- # Execute the CLI interface, and exit with the proper error code
43
- exit(env.cli(ARGV))
66
+ # Exit with the exit status from our CLI command
67
+ exit(exit_status)
44
68
  rescue Vagrant::Errors::VagrantError => e
45
69
  logger.error("Vagrant experienced an error! Details:")
46
70
  logger.error(e.inspect)
@@ -1,27 +1,32 @@
1
- Vagrant::Config.run do |config|
1
+ Vagrant.configure("2") do |config|
2
2
  # default config goes here
3
- config.vagrant.dotfile_name = ".vagrant"
4
3
  config.vagrant.host = :detect
5
4
 
6
5
  config.ssh.username = "vagrant"
7
- config.ssh.host = "127.0.0.1"
8
6
  config.ssh.guest_port = 22
9
7
  config.ssh.max_tries = 100
10
- config.ssh.timeout = 10
8
+ config.ssh.timeout = 30
11
9
  config.ssh.forward_agent = false
12
10
  config.ssh.forward_x11 = false
13
- config.ssh.shell = "bash"
11
+ config.ssh.shell = "bash -l"
14
12
 
15
- config.vm.auto_port_range = (2200..2250)
13
+ config.vm.usable_port_range = (2200..2250)
16
14
  config.vm.box_url = nil
17
15
  config.vm.base_mac = nil
18
- config.vm.forward_port 22, 2222, :name => "ssh", :auto => true
19
- config.vm.boot_mode = "headless"
16
+ config.vm.graceful_halt_retry_count = 60
17
+ config.vm.graceful_halt_retry_interval = 1
20
18
  config.vm.guest = :linux
21
19
 
20
+ # Share SSH locally by default
21
+ config.vm.network :forwarded_port,
22
+ guest: 22,
23
+ host: 2222,
24
+ id: "ssh",
25
+ auto_correct: true
26
+
22
27
  # Share the root folder. This can then be overridden by
23
28
  # other Vagrantfiles, if they wish.
24
- config.vm.share_folder("v-root", "/vagrant", ".")
29
+ config.vm.synced_folder(".", "/vagrant", :id => "vagrant-root")
25
30
 
26
31
  config.nfs.map_uid = :auto
27
32
  config.nfs.map_gid = :auto
@@ -0,0 +1,3 @@
1
+ # Autocompletion for Vagrant just put this line in your ~/.profile or link this file into it like:
2
+ # source /path/to/vagrant/contrib/bash/completion.sh
3
+ complete -W "$(echo `vagrant --help | awk '/^ /{print $1}'`;)" vagrant
@@ -1,7 +1,7 @@
1
1
  # Insecure Keypair
2
2
 
3
3
  These keys are the "insecure" public/private keypair we offer to
4
- [base box creators](http://vagrantup.com/docs/base_boxes.html) for use in their base boxes so that
4
+ [base box creators](http://docs.vagrantup.com/v1/docs/base_boxes.html) for use in their base boxes so that
5
5
  vagrant installations can automatically SSH into the boxes.
6
6
 
7
7
  If you're working with a team or company or with a custom box and
@@ -13,5 +13,5 @@ and configure the private key in the Vagrantfile with
13
13
 
14
14
  If you are using Vagrant on windows, the .ppk file contained here, in the keys directory,
15
15
  has been generated from the private key and should be used to connect Putty to any VMs that
16
- are leveraging the default key pair. See [guide](http://vagrantup.com/docs/getting-started/windows.html)
17
- in the documentation for more details on using Putty with Vagrant.
16
+ are leveraging the default key pair. See [guide](http://docs.vagrantup.com/v1/docs/getting-started/ssh.html)
17
+ in the documentation for more details on using Putty with Vagrant.
@@ -42,9 +42,11 @@ if ENV["VAGRANT_LOG"] && ENV["VAGRANT_LOG"] != ""
42
42
  end
43
43
  end
44
44
 
45
+ require 'json'
45
46
  require 'pathname'
47
+ require 'stringio'
48
+
46
49
  require 'childprocess'
47
- require 'json'
48
50
  require 'i18n'
49
51
 
50
52
  # OpenSSL must be loaded here since when it is loaded via `autoload`
@@ -53,7 +55,12 @@ require 'openssl'
53
55
 
54
56
  # Always make the version available
55
57
  require 'vagrant/version'
56
- Log4r::Logger.new("vagrant::global").info("Vagrant version: #{Vagrant::VERSION}")
58
+ global_logger = Log4r::Logger.new("vagrant::global")
59
+ global_logger.info("Vagrant version: #{Vagrant::VERSION}")
60
+
61
+ # We need these components always so instead of an autoload we
62
+ # just require them explicitly here.
63
+ require "vagrant/registry"
57
64
 
58
65
  module Vagrant
59
66
  autoload :Action, 'vagrant/action'
@@ -61,28 +68,48 @@ module Vagrant
61
68
  autoload :BoxCollection, 'vagrant/box_collection'
62
69
  autoload :CLI, 'vagrant/cli'
63
70
  autoload :Command, 'vagrant/command'
64
- autoload :Communication, 'vagrant/communication'
65
71
  autoload :Config, 'vagrant/config'
66
- autoload :DataStore, 'vagrant/data_store'
67
72
  autoload :Downloaders, 'vagrant/downloaders'
68
73
  autoload :Driver, 'vagrant/driver'
69
74
  autoload :Environment, 'vagrant/environment'
70
75
  autoload :Errors, 'vagrant/errors'
71
76
  autoload :Guest, 'vagrant/guest'
72
77
  autoload :Hosts, 'vagrant/hosts'
78
+ autoload :Machine, 'vagrant/machine'
79
+ autoload :MachineState, 'vagrant/machine_state'
73
80
  autoload :Plugin, 'vagrant/plugin'
74
- autoload :Provisioners, 'vagrant/provisioners'
75
- autoload :Registry, 'vagrant/registry'
76
- autoload :SSH, 'vagrant/ssh'
77
81
  autoload :TestHelpers, 'vagrant/test_helpers'
78
82
  autoload :UI, 'vagrant/ui'
79
83
  autoload :Util, 'vagrant/util'
80
- autoload :VM, 'vagrant/vm'
81
84
 
82
- # Returns a `Vagrant::Registry` object that contains all the built-in
83
- # middleware stacks.
84
- def self.actions
85
- @actions ||= Vagrant::Action::Builtin.new
85
+ # These are the various plugin versions and their components in
86
+ # a lazy loaded Hash-like structure.
87
+ PLUGIN_COMPONENTS = Registry.new.tap do |c|
88
+ c.register(:"1") { Plugin::V1::Plugin }
89
+ c.register([:"1", :command]) { Plugin::V1::Command }
90
+ c.register([:"1", :communicator]) { Plugin::V1::Communicator }
91
+ c.register([:"1", :config]) { Plugin::V1::Config }
92
+ c.register([:"1", :guest]) { Plugin::V1::Guest }
93
+ c.register([:"1", :host]) { Plugin::V1::Host }
94
+ c.register([:"1", :provider]) { Plugin::V1::Provider }
95
+ c.register([:"1", :provisioner]) { Plugin::V1::Provisioner }
96
+
97
+ c.register(:"2") { Plugin::V2::Plugin }
98
+ c.register([:"2", :command]) { Plugin::V2::Command }
99
+ c.register([:"2", :communicator]) { Plugin::V2::Communicator }
100
+ c.register([:"2", :config]) { Plugin::V2::Config }
101
+ c.register([:"2", :guest]) { Plugin::V2::Guest }
102
+ c.register([:"2", :host]) { Plugin::V2::Host }
103
+ c.register([:"2", :provider]) { Plugin::V2::Provider }
104
+ c.register([:"2", :provisioner]) { Plugin::V2::Provisioner }
105
+ end
106
+
107
+ # This returns a true/false showing whether we're running from the
108
+ # environment setup by the Vagrant installers.
109
+ #
110
+ # @return [Boolean]
111
+ def self.in_installer?
112
+ !!ENV["VAGRANT_INSTALLER_ENV"]
86
113
  end
87
114
 
88
115
  # The source root is the path to the root directory of
@@ -91,107 +118,134 @@ module Vagrant
91
118
  @source_root ||= Pathname.new(File.expand_path('../../', __FILE__))
92
119
  end
93
120
 
94
- # Global registry of commands that are available via the CLI.
121
+ # Configure a Vagrant environment. The version specifies the version
122
+ # of the configuration that is expected by the block. The block, based
123
+ # on that version, configures the environment.
95
124
  #
96
- # This registry is used to look up the sub-commands that are available
97
- # to Vagrant.
98
- def self.commands
99
- @commands ||= Registry.new
100
- end
101
-
102
- # Global registry of config keys that are available.
125
+ # Note that the block isn't run immediately. Instead, the configuration
126
+ # block is stored until later, and is run when an environment is loaded.
103
127
  #
104
- # This registry is used to look up the keys for `config` objects.
105
- # For example, `config.vagrant` looks up the `:vagrant` config key
106
- # for the configuration class to use.
107
- def self.config_keys
108
- @config_keys ||= Registry.new
128
+ # @param [String] version Version of the configuration
129
+ def self.configure(version, &block)
130
+ Config.run(version, &block)
109
131
  end
110
132
 
111
- # Global registry of available host classes and shortcut symbols
112
- # associated with them.
133
+ # Returns a superclass to use when creating a plugin for Vagrant.
134
+ # Given a specific version, this returns a proper superclass to use
135
+ # to register plugins for that version.
113
136
  #
114
- # This registry is used to look up the shorcuts for `config.vagrant.host`,
115
- # or to query all hosts for automatically detecting the host system.
116
- # The registry is global to all of Vagrant.
117
- def self.hosts
118
- @hosts ||= Registry.new
119
- end
120
-
121
- # Global registry of available guest classes and shortcut symbols
122
- # associated with them.
137
+ # Optionally, if you give a specific component, then it will return
138
+ # the proper superclass for that component as well.
139
+ #
140
+ # Plugins and plugin components should subclass the classes returned by
141
+ # this method. This method lets Vagrant core control these superclasses
142
+ # and change them over time without affecting plugins. For example, if
143
+ # the V1 superclass happens to be "Vagrant::V1," future versions of
144
+ # Vagrant may move it to "Vagrant::Plugins::V1" and plugins will not be
145
+ # affected.
123
146
  #
124
- # This registry is used to look up the shortcuts for `config.vm.guest`.
125
- def self.guests
126
- @guests ||= Registry.new
147
+ # @return [Class]
148
+ def self.plugin(version, component=nil)
149
+ # Build up the key and return a result
150
+ key = version.to_sym
151
+ key = [key, component.to_sym] if component
152
+ result = PLUGIN_COMPONENTS.get(key)
153
+
154
+ # If we found our component then we return that
155
+ return result if result
156
+
157
+ # If we didn't find a result, then raise an exception, depending
158
+ # on if we got a component or not.
159
+ raise ArgumentError, "Plugin superclass not found for version/component: " +
160
+ "#{version} #{component}"
127
161
  end
128
162
 
129
- # Global registry of provisioners.
163
+ # This should be used instead of Ruby's built-in `require` in order to
164
+ # load a Vagrant plugin. This will load the given plugin by first doing
165
+ # a normal `require`, giving a nice error message if things go wrong,
166
+ # and second by verifying that a Vagrant plugin was actually defined in
167
+ # the process.
130
168
  #
131
- # This registry is used to look up the provisioners provided for
132
- # `config.vm.provision`.
133
- def self.provisioners
134
- @provisioners ||= Registry.new
169
+ # @param [String] name Name of the plugin to load.
170
+ def self.require_plugin(name)
171
+ # Redirect stdout/stderr so that we can output it in our own way.
172
+ previous_stderr = $stderr
173
+ previous_stdout = $stdout
174
+ $stderr = StringIO.new
175
+ $stdout = StringIO.new
176
+
177
+ # Attempt the normal require
178
+ begin
179
+ require name
180
+ rescue Exception => e
181
+ # Since this is a rare case, we create a one-time logger here
182
+ # in order to output the error
183
+ logger = Log4r::Logger.new("vagrant::root")
184
+ logger.error("Failed to load plugin: #{name}")
185
+ logger.error(" -- Error: #{e.inspect}")
186
+ logger.error(" -- Backtrace:")
187
+ logger.error(e.backtrace.join("\n"))
188
+
189
+ # If it is a LoadError we first try to see if it failed loading
190
+ # the top-level entrypoint. If so, then we report a different error.
191
+ if e.is_a?(LoadError)
192
+ # Parse the message in order to get what failed to load, and
193
+ # add some extra protection around if the message is different.
194
+ parts = e.to_s.split(" -- ", 2)
195
+ if parts.length == 2 && parts[1] == name
196
+ raise Errors::PluginLoadError, :plugin => name
197
+ end
198
+ end
199
+
200
+ # Get the string data out from the stdout/stderr captures
201
+ stderr = $stderr.string
202
+ stdout = $stdout.string
203
+ if !stderr.empty? || !stdout.empty?
204
+ raise Errors::PluginLoadFailedWithOutput,
205
+ :plugin => name,
206
+ :stderr => stderr,
207
+ :stdout => stdout
208
+ end
209
+
210
+ # And raise an error itself
211
+ raise Errors::PluginLoadFailed,
212
+ :plugin => name
213
+ end
214
+ ensure
215
+ $stderr = previous_stderr
216
+ $stdout = previous_stdout
135
217
  end
136
218
  end
137
219
 
138
- # # Default I18n to load the en locale
220
+ # Default I18n to load the en locale
139
221
  I18n.load_path << File.expand_path("templates/locales/en.yml", Vagrant.source_root)
140
222
 
141
- # Register the built-in commands
142
- Vagrant.commands.register(:box) { Vagrant::Command::Box }
143
- Vagrant.commands.register(:destroy) { Vagrant::Command::Destroy }
144
- Vagrant.commands.register(:gem) { Vagrant::Command::Gem }
145
- Vagrant.commands.register(:halt) { Vagrant::Command::Halt }
146
- Vagrant.commands.register(:init) { Vagrant::Command::Init }
147
- Vagrant.commands.register(:package) { Vagrant::Command::Package }
148
- Vagrant.commands.register(:provision) { Vagrant::Command::Provision }
149
- Vagrant.commands.register(:reload) { Vagrant::Command::Reload }
150
- Vagrant.commands.register(:resume) { Vagrant::Command::Resume }
151
- Vagrant.commands.register(:ssh) { Vagrant::Command::SSH }
152
- Vagrant.commands.register(:"ssh-config") { Vagrant::Command::SSHConfig }
153
- Vagrant.commands.register(:status) { Vagrant::Command::Status }
154
- Vagrant.commands.register(:suspend) { Vagrant::Command::Suspend }
155
- Vagrant.commands.register(:up) { Vagrant::Command::Up }
156
-
157
- # Register the built-in config keys
158
- Vagrant.config_keys.register(:vagrant) { Vagrant::Config::VagrantConfig }
159
- Vagrant.config_keys.register(:ssh) { Vagrant::Config::SSHConfig }
160
- Vagrant.config_keys.register(:nfs) { Vagrant::Config::NFSConfig }
161
- Vagrant.config_keys.register(:vm) { Vagrant::Config::VMConfig }
162
- Vagrant.config_keys.register(:package) { Vagrant::Config::PackageConfig }
163
-
164
- # Register the built-in hosts
165
- Vagrant.hosts.register(:arch) { Vagrant::Hosts::Arch }
166
- Vagrant.hosts.register(:bsd) { Vagrant::Hosts::BSD }
167
- Vagrant.hosts.register(:fedora) { Vagrant::Hosts::Fedora }
168
- Vagrant.hosts.register(:opensuse) { Vagrant::Hosts::OpenSUSE }
169
- Vagrant.hosts.register(:freebsd) { Vagrant::Hosts::FreeBSD }
170
- Vagrant.hosts.register(:gentoo) { Vagrant::Hosts::Gentoo }
171
- Vagrant.hosts.register(:linux) { Vagrant::Hosts::Linux }
172
- Vagrant.hosts.register(:windows) { Vagrant::Hosts::Windows }
173
-
174
- # Register the built-in guests
175
- Vagrant.guests.register(:arch) { Vagrant::Guest::Arch }
176
- Vagrant.guests.register(:debian) { Vagrant::Guest::Debian }
177
- Vagrant.guests.register(:fedora) { Vagrant::Guest::Fedora }
178
- Vagrant.guests.register(:freebsd) { Vagrant::Guest::FreeBSD }
179
- Vagrant.guests.register(:gentoo) { Vagrant::Guest::Gentoo }
180
- Vagrant.guests.register(:linux) { Vagrant::Guest::Linux }
181
- Vagrant.guests.register(:openbsd) { Vagrant::Guest::OpenBSD }
182
- Vagrant.guests.register(:redhat) { Vagrant::Guest::Redhat }
183
- Vagrant.guests.register(:solaris) { Vagrant::Guest::Solaris }
184
- Vagrant.guests.register(:suse) { Vagrant::Guest::Suse }
185
- Vagrant.guests.register(:ubuntu) { Vagrant::Guest::Ubuntu }
186
-
187
- # Register the built-in provisioners
188
- Vagrant.provisioners.register(:chef_solo) { Vagrant::Provisioners::ChefSolo }
189
- Vagrant.provisioners.register(:chef_client) { Vagrant::Provisioners::ChefClient }
190
- Vagrant.provisioners.register(:puppet) { Vagrant::Provisioners::Puppet }
191
- Vagrant.provisioners.register(:puppet_server) { Vagrant::Provisioners::PuppetServer }
192
- Vagrant.provisioners.register(:shell) { Vagrant::Provisioners::Shell }
193
-
194
- # Register the built-in systems
195
- Vagrant.config_keys.register(:freebsd) { Vagrant::Guest::FreeBSD::FreeBSDConfig }
196
- Vagrant.config_keys.register(:linux) { Vagrant::Guest::Linux::LinuxConfig }
197
- Vagrant.config_keys.register(:solaris) { Vagrant::Guest::Solaris::SolarisConfig }
223
+ # A lambda that knows how to load plugins from a single directory.
224
+ plugin_load_proc = lambda do |directory|
225
+ # We only care about directories
226
+ next false if !directory.directory?
227
+
228
+ # If there is a plugin file in the top-level directory, then load
229
+ # that up.
230
+ plugin_file = directory.join("plugin.rb")
231
+ if plugin_file.file?
232
+ global_logger.debug("Loading core plugin: #{plugin_file}")
233
+ load(plugin_file)
234
+ next true
235
+ end
236
+ end
237
+
238
+ # Go through the `plugins` directory and attempt to load any plugins. The
239
+ # plugins are allowed to be in a directory in `plugins` or at most one
240
+ # directory deep within the plugins directory. So a plugin can be at
241
+ # `plugins/foo` or also at `plugins/foo/bar`, but no deeper.
242
+ Vagrant.source_root.join("plugins").children(true).each do |directory|
243
+ # Ignore non-directories
244
+ next if !directory.directory?
245
+
246
+ # Load from this directory, and exit if we successfully loaded a plugin
247
+ next if plugin_load_proc.call(directory)
248
+
249
+ # Otherwise, attempt to load from sub-directories
250
+ directory.children(true).each(&plugin_load_proc)
251
+ end