veewee 0.3.0.beta1 → 0.3.0.beta2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (211) hide show
  1. data/README.md +7 -7
  2. data/Rakefile +29 -10
  3. data/bin/veewee +5 -0
  4. data/doc/vagrant.md +2 -2
  5. data/lib/veewee/command/fusion.rb +1 -0
  6. data/lib/veewee/command/kvm.rb +1 -0
  7. data/lib/veewee/command/parallels.rb +1 -0
  8. data/lib/veewee/command/vagrant/validate.rb +5 -3
  9. data/lib/veewee/command/vbox.rb +1 -0
  10. data/lib/veewee/config/ostypes.yml +36 -2
  11. data/lib/veewee/definition.rb +2 -2
  12. data/lib/veewee/environment.rb +3 -1
  13. data/lib/veewee/provider/core/box.rb +2 -0
  14. data/lib/veewee/provider/core/box/build.rb +2 -2
  15. data/lib/veewee/provider/core/box/scp.rb +1 -1
  16. data/lib/veewee/provider/core/box/validate_tags.rb +58 -0
  17. data/lib/veewee/provider/core/provider.rb +5 -0
  18. data/lib/veewee/provider/kvm/box/create.rb +2 -2
  19. data/lib/veewee/provider/kvm/box/helper/console_type.rb +3 -3
  20. data/lib/veewee/provider/kvm/box/helper/ip.rb +2 -2
  21. data/lib/veewee/provider/kvm/box/helper/status.rb +2 -2
  22. data/lib/veewee/provider/kvm/box/validate_kvm.rb +1 -33
  23. data/lib/veewee/provider/kvm/provider.rb +1 -1
  24. data/lib/veewee/provider/parallels/box/validate_parallels.rb +1 -35
  25. data/lib/veewee/provider/virtualbox/box/helper/create.rb +3 -3
  26. data/lib/veewee/provider/virtualbox/box/validate_vagrant.rb +2 -42
  27. data/lib/veewee/provider/vmfusion/box/helper/buildinfo.rb +7 -3
  28. data/lib/veewee/provider/vmfusion/box/template.rb +9 -0
  29. data/lib/veewee/provider/vmfusion/box/template.vmx.erb +1 -1
  30. data/lib/veewee/provider/vmfusion/box/validate_vmfusion.rb +1 -35
  31. data/lib/veewee/provider/vmfusion/provider.rb +14 -10
  32. data/lib/veewee/version.rb +1 -1
  33. data/templates/CentOS-6.0-i386-netboot/base.sh +14 -0
  34. data/templates/CentOS-6.0-i386-netboot/chef.sh +3 -0
  35. data/templates/CentOS-6.0-i386-netboot/cleanup.sh +5 -0
  36. data/templates/CentOS-6.0-i386-netboot/definition.rb +33 -9
  37. data/templates/CentOS-6.0-i386-netboot/ks.cfg +19 -30
  38. data/templates/CentOS-6.0-i386-netboot/puppet.sh +12 -0
  39. data/templates/CentOS-6.0-i386-netboot/ruby.sh +3 -0
  40. data/templates/CentOS-6.0-i386-netboot/vagrant.sh +18 -0
  41. data/templates/CentOS-6.0-i386-netboot/virtualbox.sh +8 -0
  42. data/templates/CentOS-6.0-i386-netboot/zerodisk.sh +3 -0
  43. data/templates/CentOS-6.0-i386/base.sh +22 -0
  44. data/templates/CentOS-6.0-i386/chef.sh +3 -0
  45. data/templates/CentOS-6.0-i386/cleanup.sh +5 -0
  46. data/templates/CentOS-6.0-i386/definition.rb +33 -12
  47. data/templates/CentOS-6.0-i386/ks.cfg +12 -18
  48. data/templates/CentOS-6.0-i386/puppet.sh +12 -0
  49. data/templates/CentOS-6.0-i386/ruby.sh +3 -0
  50. data/templates/CentOS-6.0-i386/vagrant.sh +18 -0
  51. data/templates/CentOS-6.0-i386/virtualbox.sh +8 -0
  52. data/templates/CentOS-6.0-i386/zerodisk.sh +3 -0
  53. data/templates/CentOS-6.0-x86_64-minimal/base.sh +22 -0
  54. data/templates/CentOS-6.0-x86_64-minimal/chef.sh +3 -0
  55. data/templates/CentOS-6.0-x86_64-minimal/cleanup.sh +5 -0
  56. data/templates/CentOS-6.0-x86_64-minimal/definition.rb +33 -10
  57. data/templates/CentOS-6.0-x86_64-minimal/ks.cfg +11 -7
  58. data/templates/CentOS-6.0-x86_64-minimal/puppet.sh +12 -0
  59. data/templates/CentOS-6.0-x86_64-minimal/ruby.sh +3 -0
  60. data/templates/CentOS-6.0-x86_64-minimal/vagrant.sh +18 -0
  61. data/templates/CentOS-6.0-x86_64-minimal/virtualbox.sh +8 -0
  62. data/templates/CentOS-6.0-x86_64-minimal/zerodisk.sh +3 -0
  63. data/templates/CentOS-6.0-x86_64-netboot/base.sh +14 -0
  64. data/templates/CentOS-6.0-x86_64-netboot/chef.sh +3 -0
  65. data/templates/CentOS-6.0-x86_64-netboot/cleanup.sh +5 -0
  66. data/templates/CentOS-6.0-x86_64-netboot/definition.rb +32 -8
  67. data/templates/CentOS-6.0-x86_64-netboot/ks.cfg +18 -30
  68. data/templates/CentOS-6.0-x86_64-netboot/puppet.sh +12 -0
  69. data/templates/CentOS-6.0-x86_64-netboot/ruby.sh +3 -0
  70. data/templates/CentOS-6.0-x86_64-netboot/vagrant.sh +18 -0
  71. data/templates/CentOS-6.0-x86_64-netboot/virtualbox.sh +8 -0
  72. data/templates/CentOS-6.0-x86_64-netboot/zerodisk.sh +3 -0
  73. data/templates/CentOS-6.0-x86_64/base.sh +10 -0
  74. data/templates/CentOS-6.0-x86_64/chef.sh +1 -0
  75. data/templates/CentOS-6.0-x86_64/cleanup.sh +1 -0
  76. data/templates/CentOS-6.0-x86_64/definition.rb +16 -7
  77. data/templates/CentOS-6.0-x86_64/ks.cfg +12 -18
  78. data/templates/CentOS-6.0-x86_64/puppet.sh +1 -0
  79. data/templates/CentOS-6.0-x86_64/ruby.sh +2 -1
  80. data/templates/CentOS-6.0-x86_64/vagrant.sh +13 -4
  81. data/templates/CentOS-6.0-x86_64/virtualbox.sh +4 -4
  82. data/templates/CentOS-6.0-x86_64/zerodisk.sh +3 -0
  83. data/templates/CentOS-6.1-x86_64-minimal/base.sh +10 -1
  84. data/templates/CentOS-6.1-x86_64-minimal/chef.sh +1 -0
  85. data/templates/CentOS-6.1-x86_64-minimal/cleanup.sh +1 -0
  86. data/templates/CentOS-6.1-x86_64-minimal/definition.rb +3 -2
  87. data/templates/CentOS-6.1-x86_64-minimal/ks.cfg +13 -18
  88. data/templates/CentOS-6.1-x86_64-minimal/puppet.sh +1 -0
  89. data/templates/CentOS-6.1-x86_64-minimal/ruby.sh +2 -1
  90. data/templates/CentOS-6.1-x86_64-minimal/vagrant.sh +6 -4
  91. data/templates/CentOS-6.1-x86_64-minimal/virtualbox.sh +2 -2
  92. data/templates/CentOS-6.1-x86_64-minimal/zerodisk.sh +3 -0
  93. data/templates/CentOS-6.1-x86_64-netboot/base.sh +2 -1
  94. data/templates/CentOS-6.1-x86_64-netboot/chef.sh +1 -0
  95. data/templates/CentOS-6.1-x86_64-netboot/cleanup.sh +1 -0
  96. data/templates/CentOS-6.1-x86_64-netboot/definition.rb +7 -6
  97. data/templates/CentOS-6.1-x86_64-netboot/ks.cfg +13 -17
  98. data/templates/CentOS-6.1-x86_64-netboot/puppet.sh +1 -0
  99. data/templates/CentOS-6.1-x86_64-netboot/ruby.sh +2 -1
  100. data/templates/CentOS-6.1-x86_64-netboot/vagrant.sh +6 -4
  101. data/templates/CentOS-6.1-x86_64-netboot/virtualbox.sh +3 -3
  102. data/templates/CentOS-6.1-x86_64-netboot/zerodisk.sh +3 -0
  103. data/templates/CentOS-6.2-i386-minimal/base.sh +8 -0
  104. data/templates/CentOS-6.2-i386-minimal/definition.rb +3 -2
  105. data/templates/CentOS-6.2-i386-minimal/ks.cfg +4 -1
  106. data/templates/CentOS-6.2-i386-minimal/vagrant.sh +5 -4
  107. data/templates/CentOS-6.2-i386-minimal/zerodisk.sh +3 -0
  108. data/templates/CentOS-6.2-x86_64-minimal/base.sh +8 -0
  109. data/templates/CentOS-6.2-x86_64-minimal/definition.rb +3 -2
  110. data/templates/CentOS-6.2-x86_64-minimal/ks.cfg +4 -1
  111. data/templates/CentOS-6.2-x86_64-minimal/vagrant.sh +5 -4
  112. data/templates/CentOS-6.2-x86_64-minimal/zerodisk.sh +3 -0
  113. data/templates/CentOS-6.2-x86_64-netboot/base.sh +2 -1
  114. data/templates/CentOS-6.2-x86_64-netboot/chef.sh +1 -0
  115. data/templates/CentOS-6.2-x86_64-netboot/cleanup.sh +1 -0
  116. data/templates/CentOS-6.2-x86_64-netboot/definition.rb +7 -6
  117. data/templates/CentOS-6.2-x86_64-netboot/ks.cfg +13 -17
  118. data/templates/CentOS-6.2-x86_64-netboot/puppet.sh +1 -0
  119. data/templates/CentOS-6.2-x86_64-netboot/ruby.sh +2 -1
  120. data/templates/CentOS-6.2-x86_64-netboot/vagrant.sh +6 -4
  121. data/templates/CentOS-6.2-x86_64-netboot/virtualbox.sh +3 -3
  122. data/templates/CentOS-6.2-x86_64-netboot/zerodisk.sh +3 -0
  123. data/templates/CentOS-6.3-i386-minimal/definition.rb +2 -1
  124. data/templates/CentOS-6.3-i386-minimal/vagrant.sh +5 -4
  125. data/templates/CentOS-6.3-i386-minimal/zerodisk.sh +3 -0
  126. data/templates/CentOS-6.3-x86_64-minimal/definition.rb +2 -1
  127. data/templates/CentOS-6.3-x86_64-minimal/vagrant.sh +5 -4
  128. data/templates/CentOS-6.3-x86_64-minimal/zerodisk.sh +3 -0
  129. data/templates/Debian-5.0.10-amd64-netboot/base.sh +9 -0
  130. data/templates/Debian-5.0.10-amd64-netboot/chef.sh +2 -0
  131. data/templates/Debian-5.0.10-amd64-netboot/cleanup.sh +10 -0
  132. data/templates/Debian-5.0.10-amd64-netboot/definition.rb +39 -0
  133. data/templates/Debian-5.0.10-amd64-netboot/postinstall.sh +60 -0
  134. data/templates/Debian-5.0.10-amd64-netboot/preseed.cfg +312 -0
  135. data/templates/Debian-5.0.10-amd64-netboot/puppet.sh +2 -0
  136. data/templates/Debian-5.0.10-amd64-netboot/ruby.sh +11 -0
  137. data/templates/Debian-5.0.10-amd64-netboot/vagrant.sh +14 -0
  138. data/templates/Debian-5.0.10-amd64-netboot/virtualbox.sh +15 -0
  139. data/templates/Debian-5.0.10-i386-netboot/base.sh +9 -0
  140. data/templates/Debian-5.0.10-i386-netboot/chef.sh +2 -0
  141. data/templates/Debian-5.0.10-i386-netboot/cleanup.sh +10 -0
  142. data/templates/Debian-5.0.10-i386-netboot/definition.rb +39 -0
  143. data/templates/Debian-5.0.10-i386-netboot/postinstall.sh +60 -0
  144. data/templates/Debian-5.0.10-i386-netboot/preseed.cfg +312 -0
  145. data/templates/Debian-5.0.10-i386-netboot/puppet.sh +2 -0
  146. data/templates/Debian-5.0.10-i386-netboot/ruby.sh +11 -0
  147. data/templates/Debian-5.0.10-i386-netboot/vagrant.sh +14 -0
  148. data/templates/Debian-5.0.10-i386-netboot/virtualbox.sh +15 -0
  149. data/templates/Debian-5.0.8-amd64-netboot/preseed.cfg +2 -2
  150. data/templates/Debian-5.0.8-i386-netboot/preseed.cfg +2 -2
  151. data/templates/Debian-6.0.4-amd64-netboot/definition.rb +1 -1
  152. data/templates/Debian-6.0.4-amd64-netboot/vagrant.sh +5 -1
  153. data/templates/Debian-6.0.4-i386-netboot/definition.rb +1 -1
  154. data/templates/Debian-6.0.4-i386-netboot/vagrant.sh +5 -1
  155. data/templates/Debian-6.0.5-amd64-netboot/vagrant.sh +5 -1
  156. data/templates/Debian-6.0.5-i386-netboot/vagrant.sh +5 -1
  157. data/templates/SLES-11-SP1-DVD-i586-GM/postinstall.sh +3 -0
  158. data/templates/SLES-11-SP1-DVD-x86_64-GM/postinstall.sh +3 -0
  159. data/templates/gentoo-latest-i386-experimental/definition.rb +20 -4
  160. data/templates/gentoo-latest-x86_64-experimental/definition.rb +23 -12
  161. data/templates/scientificlinux-6.1-i386-netboot/definition.rb +1 -2
  162. data/templates/scientificlinux-6.3-i386-netboot/base.sh +1 -0
  163. data/templates/scientificlinux-6.3-i386-netboot/chef.sh +1 -0
  164. data/templates/scientificlinux-6.3-i386-netboot/cleanup.sh +4 -0
  165. data/templates/scientificlinux-6.3-i386-netboot/definition.rb +37 -0
  166. data/templates/scientificlinux-6.3-i386-netboot/ks.cfg +53 -0
  167. data/templates/{CentOS-6.0-i386-netboot → scientificlinux-6.3-i386-netboot}/postinstall.sh +2 -2
  168. data/templates/scientificlinux-6.3-i386-netboot/puppet.sh +1 -0
  169. data/templates/scientificlinux-6.3-i386-netboot/ruby.sh +1 -0
  170. data/templates/scientificlinux-6.3-i386-netboot/vagrant.sh +8 -0
  171. data/templates/scientificlinux-6.3-i386-netboot/virtualbox.sh +8 -0
  172. data/templates/scientificlinux-6.3-x86_64-netboot/base.sh +1 -0
  173. data/templates/scientificlinux-6.3-x86_64-netboot/chef.sh +1 -0
  174. data/templates/scientificlinux-6.3-x86_64-netboot/cleanup.sh +4 -0
  175. data/templates/scientificlinux-6.3-x86_64-netboot/definition.rb +37 -0
  176. data/templates/scientificlinux-6.3-x86_64-netboot/ks.cfg +53 -0
  177. data/templates/{CentOS-6.0-x86_64-netboot → scientificlinux-6.3-x86_64-netboot}/postinstall.sh +2 -2
  178. data/templates/scientificlinux-6.3-x86_64-netboot/puppet.sh +1 -0
  179. data/templates/scientificlinux-6.3-x86_64-netboot/ruby.sh +1 -0
  180. data/templates/scientificlinux-6.3-x86_64-netboot/rvm-ruby.sh +9 -0
  181. data/templates/scientificlinux-6.3-x86_64-netboot/vagrant.sh +8 -0
  182. data/templates/scientificlinux-6.3-x86_64-netboot/virtualbox.sh +8 -0
  183. data/templates/ubuntu-10.04.3-server-i386/postinstall.sh +5 -5
  184. data/templates/{ubuntu-12.04-server-amd64-packages → ubuntu-12.04.1-server-amd64-packages}/definition.rb +3 -3
  185. data/templates/{ubuntu-12.04-server-amd64-packages → ubuntu-12.04.1-server-amd64-packages}/postinstall.sh +0 -0
  186. data/templates/{ubuntu-12.04-server-amd64-packages → ubuntu-12.04.1-server-amd64-packages}/preseed.cfg +0 -0
  187. data/templates/{ubuntu-12.04-server-amd64 → ubuntu-12.04.1-server-amd64}/definition.rb +3 -3
  188. data/templates/{ubuntu-12.04-server-amd64 → ubuntu-12.04.1-server-amd64}/postinstall.sh +0 -0
  189. data/templates/{ubuntu-12.04-server-amd64 → ubuntu-12.04.1-server-amd64}/preseed.cfg +0 -0
  190. data/templates/{ubuntu-12.04-server-i386-packages → ubuntu-12.04.1-server-i386-packages}/definition.rb +3 -3
  191. data/templates/{ubuntu-12.04-server-i386-packages → ubuntu-12.04.1-server-i386-packages}/postinstall.sh +0 -0
  192. data/templates/{ubuntu-12.04-server-i386-packages → ubuntu-12.04.1-server-i386-packages}/preseed.cfg +0 -0
  193. data/templates/{ubuntu-12.04-server-i386 → ubuntu-12.04.1-server-i386}/definition.rb +3 -3
  194. data/templates/{ubuntu-12.04-server-i386 → ubuntu-12.04.1-server-i386}/postinstall.sh +0 -0
  195. data/templates/{ubuntu-12.04-server-i386 → ubuntu-12.04.1-server-i386}/preseed.cfg +0 -0
  196. data/templates/{windows-8-preview-dev-amd64 → windows-8-preview-amd64}/Autounattend.xml +0 -0
  197. data/templates/{windows-8-preview-dev-amd64 → windows-8-preview-amd64}/README.md +0 -0
  198. data/templates/{windows-8-preview-dev-amd64 → windows-8-preview-amd64}/cygwin-setup.exe +0 -0
  199. data/templates/{windows-8-preview-dev-amd64 → windows-8-preview-amd64}/definition.rb +3 -3
  200. data/templates/{windows-8-preview-dev-amd64 → windows-8-preview-amd64}/install-cygwin-sshd.bat +0 -0
  201. data/templates/{windows-8-preview-dev-amd64 → windows-8-preview-amd64}/install-winrm.bat +0 -0
  202. data/templates/{windows-8-preview-dev-amd64 → windows-8-preview-amd64}/oracle-cert.cer +0 -0
  203. data/templates/{windows-8-preview-dev-amd64 → windows-8-preview-amd64}/postinstall.sh +0 -0
  204. data/templates/{windows-8-preview-dev-amd64 → windows-8-preview-amd64}/winrm.rb +0 -0
  205. data/validation/veewee.feature +6 -6
  206. metadata +306 -157
  207. data/templates/CentOS-6.0-i386/postinstall.sh +0 -48
  208. data/templates/CentOS-6.0-x86_64-minimal/postinstall.sh +0 -58
  209. data/templates/CentOS-6.0-x86_64/postinstall.sh +0 -48
  210. data/templates/CentOS-6.1-x86_64-netboot/postinstall.sh +0 -48
  211. data/templates/CentOS-6.2-x86_64-netboot/postinstall.sh +0 -48
@@ -0,0 +1,8 @@
1
+ # Installing the virtualbox guest additions
2
+ VBOX_VERSION=$(cat /home/veewee/.vbox_version)
3
+ cd /tmp
4
+ mount -o loop /home/veewee/VBoxGuestAdditions_$VBOX_VERSION.iso /mnt
5
+ sh /mnt/VBoxLinuxAdditions.run
6
+ umount /mnt
7
+ rm -rf /home/veewee/VBoxGuestAdditions_*.iso
8
+
@@ -0,0 +1,3 @@
1
+ # Zero out the free space to save space in the final image:
2
+ dd if=/dev/zero of=/EMPTY bs=1M
3
+ rm -f /EMPTY
@@ -0,0 +1,22 @@
1
+ # Base install
2
+
3
+ sed -i "s/^.*requiretty/#Defaults requiretty/" /etc/sudoers
4
+
5
+ cat > /etc/yum.repos.d/epel.repo << EOM
6
+ [epel]
7
+ name=epel
8
+ baseurl=http://download.fedoraproject.org/pub/epel/6/\$basearch
9
+ enabled=1
10
+ gpgcheck=0
11
+ EOM
12
+
13
+ cat > /etc/yum.repos.d/centos-vault.repo << EOM
14
+ [vault]
15
+ name=vault
16
+ baseurl=http://vault.centos.org/6.0/os/\$basearch
17
+ enabled=1
18
+ gpgcheck=0
19
+ EOM
20
+
21
+ yum -y install gcc make gcc-c++ kernel-devel-`uname -r` zlib-devel openssl-devel readline-devel sqlite-devel perl wget
22
+
@@ -0,0 +1,3 @@
1
+ # Install Chef
2
+ gem install --no-ri --no-rdoc chef
3
+
@@ -0,0 +1,5 @@
1
+ yum -y erase gtk2 libX11 hicolor-icon-theme avahi freetype bitstream-vera-fonts
2
+ yum -y clean all
3
+ rm -rf /etc/yum.repos.d/{puppetlabs,epel}.repo
4
+ rm -rf VBoxGuestAdditions_*.iso
5
+
@@ -1,19 +1,40 @@
1
- Veewee::Definition.declare({
2
- :cpu_count => '1', :memory_size=> '384',
3
- :disk_size => '10140', :disk_format => 'VDI', :hostiocache => 'off',
4
- :os_type_id => 'RedHat',
1
+ Veewee::Session.declare({
2
+ :cpu_count => '1',
3
+ :memory_size=> '480',
4
+ :disk_size => '10140',
5
+ :disk_format => 'VDI',
6
+ :hostiocache => 'off',
7
+ :os_type_id => 'RedHat_64',
5
8
  :iso_file => "CentOS-6.0-i386-bin-DVD.iso",
6
9
  :iso_src => "http://vault.centos.org/6.0/isos/i386/CentOS-6.0-i386-bin-DVD.iso",
7
- :iso_md5 => "d7e57d6edaca1556d5bad2fa88602309", :iso_download_timeout => 1000,
8
- :iso_download_instructions => "We can not download the ISO , you need to download it yourself and put it in the iso directory\n"+
9
- "- URL: http://isoredirect.centos.org/centos/6/isos/i386/",
10
- :boot_wait => "10", :boot_cmd_sequence => [
10
+ :iso_md5 => "d7e57d6edaca1556d5bad2fa88602309",
11
+ :iso_download_timeout => 1000,
12
+ :boot_wait => "10",
13
+ :boot_cmd_sequence => [
11
14
  '<Tab> text ks=http://%IP%:%PORT%/ks.cfg<Enter>'
12
15
  ],
13
- :kickstart_port => "7122", :kickstart_timeout => 10000, :kickstart_file => "ks.cfg",
14
- :ssh_login_timeout => "10000", :ssh_user => "vagrant", :ssh_password => "vagrant", :ssh_key => "",
15
- :ssh_host_port => "7222", :ssh_guest_port => "22",
16
+ :kickstart_port => "7122",
17
+ :kickstart_timeout => 10000,
18
+ :kickstart_file => "ks.cfg",
19
+ :ssh_login_timeout => "10000",
20
+ :ssh_user => "veewee",
21
+ :ssh_password => "veewee",
22
+ :ssh_key => "",
23
+ :ssh_host_port => "7222",
24
+ :ssh_guest_port => "22",
16
25
  :sudo_cmd => "echo '%p'|sudo -S sh '%f'",
17
26
  :shutdown_cmd => "/sbin/halt -h -p",
18
- :postinstall_files => [ "postinstall.sh"], :postinstall_timeout => 10000
27
+ :postinstall_files => [
28
+ "base.sh",
29
+ "ruby.sh",
30
+ "chef.sh",
31
+ "puppet.sh",
32
+ "vagrant.sh",
33
+ "virtualbox.sh",
34
+ #"kvm.sh",
35
+ #"vmfusion.sh",
36
+ "cleanup.sh",
37
+ "zerodisk.sh"
38
+ ],
39
+ :postinstall_timeout => 10000
19
40
  })
@@ -7,7 +7,7 @@ rootpw --iscrypted $1$damlkd,f$UC/u5pUts5QiU3ow.CSso/
7
7
  firewall --enabled --service=ssh
8
8
  authconfig --enableshadow --passalgo=sha512
9
9
  selinux --disabled
10
- timezone Europe/Brussels
10
+ timezone UTC
11
11
  bootloader --location=mbr
12
12
 
13
13
  text
@@ -21,28 +21,22 @@ auth --useshadow --enablemd5
21
21
  firstboot --disabled
22
22
  reboot
23
23
 
24
- repo --name=updates --baseurl=http://mirror.centos.org/centos/6/updates/i386 --includepkgs='ruby' --excludepkgs='*'
25
-
26
24
  %packages --ignoremissing
27
25
  @core
28
- ruby
29
- kernel-devel-`uname -r`
30
- gcc
31
26
  bzip2
32
- make
33
- gcc-c++
34
- zlib-devel
35
- openssl-devel
36
- readline-devel
37
- sqlite-devel
38
-
27
+ kernel-devel
28
+ kernel-headers
39
29
  -ipw2100-firmware
40
30
  -ipw2200-firmware
41
31
  -ivtv-firmware
32
+ %end
42
33
 
43
34
  %post
44
- /usr/sbin/groupadd vagrant
45
- /usr/sbin/useradd vagrant -g vagrant -G wheel
46
- echo "vagrant"|passwd --stdin vagrant
47
- echo "vagrant ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers.d/vagrant
48
- chmod 0440 /etc/sudoers.d/vagrant
35
+ /usr/bin/yum -y install sudo
36
+ /usr/sbin/groupadd veewee
37
+ /usr/sbin/useradd veewee -g veewee -G wheel
38
+ echo "veewee"|passwd --stdin veewee
39
+ echo "veewee ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers.d/veewee
40
+ chmod 0440 /etc/sudoers.d/veewee
41
+ %end
42
+
@@ -0,0 +1,12 @@
1
+ # Install Puppet
2
+
3
+ cat > /etc/yum.repos.d/puppetlabs.repo << EOM
4
+ [puppetlabs]
5
+ name=puppetlabs
6
+ baseurl=http://yum.puppetlabs.com/el/6/products/\$basearch
7
+ enabled=1
8
+ gpgcheck=0
9
+ EOM
10
+
11
+ yum -y install puppet facter
12
+
@@ -0,0 +1,3 @@
1
+ # Install Ruby
2
+ yum -y install ruby ruby-devel rubygems
3
+
@@ -0,0 +1,18 @@
1
+ # Vagrant specific
2
+ date > /etc/vagrant_box_build_time
3
+
4
+ # Add vagrant user
5
+ /usr/sbin/groupadd vagrant
6
+ /usr/sbin/useradd vagrant -g vagrant -G wheel
7
+ echo "vagrant"|passwd --stdin vagrant
8
+ echo "vagrant ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers.d/vagrant
9
+ chmod 0440 /etc/sudoers.d/vagrant
10
+
11
+ # Installing vagrant keys
12
+ mkdir -pm 700 /home/vagrant/.ssh
13
+ wget --no-check-certificate 'https://raw.github.com/mitchellh/vagrant/master/keys/vagrant.pub' -O /home/vagrant/.ssh/authorized_keys
14
+ chmod 0600 /home/vagrant/.ssh/authorized_keys
15
+ chown -R vagrant /home/vagrant/.ssh
16
+
17
+ # Customize the message of the day
18
+ echo 'Welcome to your Vagrant-built virtual machine.' > /etc/motd
@@ -0,0 +1,8 @@
1
+ # Installing the virtualbox guest additions
2
+ VBOX_VERSION=$(cat /home/veewee/.vbox_version)
3
+ cd /tmp
4
+ mount -o loop /home/veewee/VBoxGuestAdditions_$VBOX_VERSION.iso /mnt
5
+ sh /mnt/VBoxLinuxAdditions.run
6
+ umount /mnt
7
+ rm -rf /home/veewee/VBoxGuestAdditions_*.iso
8
+
@@ -0,0 +1,3 @@
1
+ # Zero out the free space to save space in the final image:
2
+ dd if=/dev/zero of=/EMPTY bs=1M
3
+ rm -f /EMPTY
@@ -0,0 +1,22 @@
1
+ # Base install
2
+
3
+ sed -i "s/^.*requiretty/#Defaults requiretty/" /etc/sudoers
4
+
5
+ cat > /etc/yum.repos.d/epel.repo << EOM
6
+ [epel]
7
+ name=epel
8
+ baseurl=http://download.fedoraproject.org/pub/epel/6/\$basearch
9
+ enabled=1
10
+ gpgcheck=0
11
+ EOM
12
+
13
+ cat > /etc/yum.repos.d/centos-vault.repo << EOM
14
+ [vault]
15
+ name=vault
16
+ baseurl=http://vault.centos.org/6.0/os/\$basearch
17
+ enabled=1
18
+ gpgcheck=0
19
+ EOM
20
+
21
+ yum -y install gcc make gcc-c++ kernel-devel-`uname -r` zlib-devel openssl-devel readline-devel sqlite-devel perl wget
22
+
@@ -0,0 +1,3 @@
1
+ # Install Chef
2
+ gem install --no-ri --no-rdoc chef
3
+
@@ -0,0 +1,5 @@
1
+ yum -y erase gtk2 libX11 hicolor-icon-theme avahi freetype bitstream-vera-fonts
2
+ yum -y clean all
3
+ rm -rf /etc/yum.repos.d/{puppetlabs,epel}.repo
4
+ rm -rf VBoxGuestAdditions_*.iso
5
+
@@ -1,17 +1,40 @@
1
1
  Veewee::Session.declare({
2
- :cpu_count => '1', :memory_size=> '384',
3
- :disk_size => '10140', :disk_format => 'VDI', :hostiocache => 'off',
2
+ :cpu_count => '1',
3
+ :memory_size=> '480',
4
+ :disk_size => '10140',
5
+ :disk_format => 'VDI',
6
+ :hostiocache => 'off',
4
7
  :os_type_id => 'RedHat_64',
5
- :iso_file => "CentOS-6.0-x86_64-minimal.iso", :iso_src => "http://vault.centos.org/6.0/isos/x86_64/CentOS-6.0-x86_64-minimal.iso", :iso_md5 => "b9fff4dad7aad0edaa564d7a251cb971", :iso_download_timeout => 1000,
6
- :iso_download_instructions => "We can not download the ISO , you need to download it yourself and put it in the iso directory\n"+
7
- "- URL: http://isoredirect.centos.org/centos/6/isos/x86_64/ ",
8
- :boot_wait => "10", :boot_cmd_sequence => [
8
+ :iso_file => "CentOS-6.0-x86_64-minimal.iso",
9
+ :iso_src => "http://vault.centos.org/6.0/isos/x86_64/CentOS-6.0-x86_64-minimal.iso",
10
+ :iso_md5 => "b9fff4dad7aad0edaa564d7a251cb971",
11
+ :iso_download_timeout => 1000,
12
+ :boot_wait => "10",
13
+ :boot_cmd_sequence => [
9
14
  '<Tab> text ks=http://%IP%:%PORT%/ks.cfg<Enter>'
10
15
  ],
11
- :kickstart_port => "7122", :kickstart_timeout => 10000, :kickstart_file => "ks.cfg",
12
- :ssh_login_timeout => "100", :ssh_user => "vagrant", :ssh_password => "vagrant", :ssh_key => "",
13
- :ssh_host_port => "7222", :ssh_guest_port => "22",
16
+ :kickstart_port => "7122",
17
+ :kickstart_timeout => 10000,
18
+ :kickstart_file => "ks.cfg",
19
+ :ssh_login_timeout => "10000",
20
+ :ssh_user => "veewee",
21
+ :ssh_password => "veewee",
22
+ :ssh_key => "",
23
+ :ssh_host_port => "7222",
24
+ :ssh_guest_port => "22",
14
25
  :sudo_cmd => "echo '%p'|sudo -S sh '%f'",
15
26
  :shutdown_cmd => "/sbin/halt -h -p",
16
- :postinstall_files => [ "postinstall.sh"], :postinstall_timeout => 10000
27
+ :postinstall_files => [
28
+ "base.sh",
29
+ "ruby.sh",
30
+ "chef.sh",
31
+ "puppet.sh",
32
+ "vagrant.sh",
33
+ "virtualbox.sh",
34
+ #"kvm.sh",
35
+ #"vmfusion.sh",
36
+ "cleanup.sh",
37
+ "zerodisk.sh"
38
+ ],
39
+ :postinstall_timeout => 10000
17
40
  })
@@ -7,7 +7,7 @@ rootpw --iscrypted $1$damlkd,f$UC/u5pUts5QiU3ow.CSso/
7
7
  firewall --enabled --service=ssh
8
8
  authconfig --enableshadow --passalgo=sha512
9
9
  selinux --disabled
10
- timezone Europe/Brussels
10
+ timezone UTC
11
11
  bootloader --location=mbr
12
12
 
13
13
  text
@@ -24,15 +24,19 @@ reboot
24
24
  %packages --ignoremissing
25
25
  @core
26
26
  bzip2
27
-
27
+ kernel-devel
28
+ kernel-headers
28
29
  -ipw2100-firmware
29
30
  -ipw2200-firmware
30
31
  -ivtv-firmware
32
+ %end
31
33
 
32
34
  %post
33
35
  /usr/bin/yum -y install sudo
34
- /usr/sbin/groupadd vagrant
35
- /usr/sbin/useradd vagrant -g vagrant -G wheel
36
- echo "vagrant"|passwd --stdin vagrant
37
- echo "vagrant ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers.d/vagrant
38
- chmod 0440 /etc/sudoers.d/vagrant
36
+ /usr/sbin/groupadd veewee
37
+ /usr/sbin/useradd veewee -g veewee -G wheel
38
+ echo "veewee"|passwd --stdin veewee
39
+ echo "veewee ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers.d/veewee
40
+ chmod 0440 /etc/sudoers.d/veewee
41
+ %end
42
+
@@ -0,0 +1,12 @@
1
+ # Install Puppet
2
+
3
+ cat > /etc/yum.repos.d/puppetlabs.repo << EOM
4
+ [puppetlabs]
5
+ name=puppetlabs
6
+ baseurl=http://yum.puppetlabs.com/el/6/products/\$basearch
7
+ enabled=1
8
+ gpgcheck=0
9
+ EOM
10
+
11
+ yum -y install puppet facter
12
+
@@ -0,0 +1,3 @@
1
+ # Install Ruby
2
+ yum -y install ruby ruby-devel rubygems
3
+
@@ -0,0 +1,18 @@
1
+ # Vagrant specific
2
+ date > /etc/vagrant_box_build_time
3
+
4
+ # Add vagrant user
5
+ /usr/sbin/groupadd vagrant
6
+ /usr/sbin/useradd vagrant -g vagrant -G wheel
7
+ echo "vagrant"|passwd --stdin vagrant
8
+ echo "vagrant ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers.d/vagrant
9
+ chmod 0440 /etc/sudoers.d/vagrant
10
+
11
+ # Installing vagrant keys
12
+ mkdir -pm 700 /home/vagrant/.ssh
13
+ wget --no-check-certificate 'https://raw.github.com/mitchellh/vagrant/master/keys/vagrant.pub' -O /home/vagrant/.ssh/authorized_keys
14
+ chmod 0600 /home/vagrant/.ssh/authorized_keys
15
+ chown -R vagrant /home/vagrant/.ssh
16
+
17
+ # Customize the message of the day
18
+ echo 'Welcome to your Vagrant-built virtual machine.' > /etc/motd
@@ -0,0 +1,8 @@
1
+ # Installing the virtualbox guest additions
2
+ VBOX_VERSION=$(cat /home/veewee/.vbox_version)
3
+ cd /tmp
4
+ mount -o loop /home/veewee/VBoxGuestAdditions_$VBOX_VERSION.iso /mnt
5
+ sh /mnt/VBoxLinuxAdditions.run
6
+ umount /mnt
7
+ rm -rf /home/veewee/VBoxGuestAdditions_*.iso
8
+
@@ -0,0 +1,3 @@
1
+ # Zero out the free space to save space in the final image:
2
+ dd if=/dev/zero of=/EMPTY bs=1M
3
+ rm -f /EMPTY
@@ -0,0 +1,14 @@
1
+ # Base install
2
+
3
+ sed -i "s/^.*requiretty/#Defaults requiretty/" /etc/sudoers
4
+
5
+ cat > /etc/yum.repos.d/epel.repo << EOM
6
+ [epel]
7
+ name=epel
8
+ baseurl=http://download.fedoraproject.org/pub/epel/6/\$basearch
9
+ enabled=1
10
+ gpgcheck=0
11
+ EOM
12
+
13
+ yum -y install gcc make gcc-c++ kernel-devel-`uname -r` zlib-devel openssl-devel readline-devel sqlite-devel perl wget
14
+
@@ -0,0 +1,3 @@
1
+ # Install Chef
2
+ gem install --no-ri --no-rdoc chef
3
+
@@ -0,0 +1,5 @@
1
+ yum -y erase gtk2 libX11 hicolor-icon-theme avahi freetype bitstream-vera-fonts
2
+ yum -y clean all
3
+ rm -rf /etc/yum.repos.d/{puppetlabs,epel}.repo
4
+ rm -rf VBoxGuestAdditions_*.iso
5
+
@@ -1,16 +1,40 @@
1
- Veewee::Definition.declare({
2
- :cpu_count => '1', :memory_size=> '392',
3
- :disk_size => '10140', :disk_format => 'VDI', :hostiocache => 'off', :ioapic => 'on', :pae => 'on',
1
+ Veewee::Session.declare({
2
+ :cpu_count => '1',
3
+ :memory_size=> '480',
4
+ :disk_size => '10140',
5
+ :disk_format => 'VDI',
6
+ :hostiocache => 'off',
4
7
  :os_type_id => 'RedHat_64',
5
8
  :iso_file => "CentOS-6.0-x86_64-netinstall.iso",
6
9
  :iso_src => "http://vault.centos.org/6.0/isos/x86_64/CentOS-6.0-x86_64-netinstall.iso",
7
10
  :iso_md5 => "d13da95c29e585ee15cf403b89468243",
8
11
  :iso_download_timeout => 1000,
9
- :boot_wait => "15", :boot_cmd_sequence => [ '<Tab> text ks=http://%IP%:%PORT%/ks.cfg<Enter>' ],
10
- :kickstart_port => "7122", :kickstart_timeout => 10000, :kickstart_file => "ks.cfg",
11
- :ssh_login_timeout => "10000", :ssh_user => "vagrant", :ssh_password => "vagrant", :ssh_key => "",
12
- :ssh_host_port => "7222", :ssh_guest_port => "22",
12
+ :boot_wait => "15",
13
+ :boot_cmd_sequence => [
14
+ '<Tab> text ks=http://%IP%:%PORT%/ks.cfg<Enter>'
15
+ ],
16
+ :kickstart_port => "7122",
17
+ :kickstart_timeout => 10000,
18
+ :kickstart_file => "ks.cfg",
19
+ :ssh_login_timeout => "10000",
20
+ :ssh_user => "veewee",
21
+ :ssh_password => "veewee",
22
+ :ssh_key => "",
23
+ :ssh_host_port => "7222",
24
+ :ssh_guest_port => "22",
13
25
  :sudo_cmd => "echo '%p'|sudo -S sh '%f'",
14
26
  :shutdown_cmd => "/sbin/halt -h -p",
15
- :postinstall_files => [ "postinstall.sh"], :postinstall_timeout => 10000
27
+ :postinstall_files => [
28
+ "base.sh",
29
+ "ruby.sh",
30
+ "chef.sh",
31
+ "puppet.sh",
32
+ "vagrant.sh",
33
+ "virtualbox.sh",
34
+ #"kvm.sh",
35
+ #"vmfusion.sh",
36
+ "cleanup.sh",
37
+ "zerodisk.sh"
38
+ ],
39
+ :postinstall_timeout => 10000
16
40
  })