veewee 0.5.0.alpha1 → 0.5.0.alpha2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (92) hide show
  1. checksums.yaml +8 -8
  2. data/Gemfile +1 -1
  3. data/lib/veewee/provider/core/helper/iso.rb +9 -5
  4. data/lib/veewee/version.rb +1 -1
  5. data/templates/{CentOS-5.10-i386-netboot → CentOS-5.10}/base.sh +0 -0
  6. data/templates/CentOS-5.10/centos_32_dvd.yml +5 -0
  7. data/templates/CentOS-5.10/centos_32_net.yml +5 -0
  8. data/templates/CentOS-5.10/centos_64_dvd.yml +5 -0
  9. data/templates/CentOS-5.10/centos_64_net.yml +5 -0
  10. data/templates/{CentOS-5.10-i386-netboot → CentOS-5.10}/chef.sh +0 -0
  11. data/templates/{CentOS-5.10-i386-netboot → CentOS-5.10}/cleanup.sh +0 -0
  12. data/templates/CentOS-5.10/definition.rb +5 -0
  13. data/templates/CentOS-5.10/definition.yml +35 -0
  14. data/templates/{CentOS-5.10-x86_64-netboot → CentOS-5.10}/ks.cfg +6 -0
  15. data/templates/{CentOS-5.10-i386-netboot → CentOS-5.10}/puppet.sh +0 -0
  16. data/templates/{CentOS-5.10-i386-netboot → CentOS-5.10}/ruby.sh +0 -0
  17. data/templates/{CentOS-5.10-i386-netboot → CentOS-5.10}/vagrant.sh +0 -0
  18. data/templates/{CentOS-5.10-i386-netboot → CentOS-5.10}/virtualbox.sh +0 -0
  19. data/templates/{CentOS-5.10-i386-netboot → CentOS-5.10}/zerodisk.sh +0 -0
  20. data/templates/Debian-5.0.10-amd64-netboot/base.sh +1 -1
  21. data/templates/Debian-5.0.10-amd64-netboot/vagrant.sh +1 -1
  22. data/templates/Debian-5.0.10-i386-netboot/base.sh +1 -1
  23. data/templates/Debian-5.0.10-i386-netboot/vagrant.sh +1 -1
  24. data/templates/Debian-5.0.8-amd64-netboot/base.sh +1 -1
  25. data/templates/Debian-5.0.8-amd64-netboot/vagrant.sh +1 -1
  26. data/templates/Debian-5.0.8-i386-netboot/base.sh +1 -1
  27. data/templates/Debian-5.0.8-i386-netboot/vagrant.sh +1 -1
  28. data/templates/Debian-6.0.6-amd64-netboot/base.sh +1 -1
  29. data/templates/Debian-7.0-amd64-netboot/base.sh +1 -1
  30. data/templates/Debian-7.0-i386-netboot/base.sh +1 -1
  31. data/templates/Debian-7.1.0-amd64-netboot/base.sh +1 -1
  32. data/templates/Debian-7.1.0-i386-netboot/base.sh +1 -1
  33. data/templates/Debian-7.2.0-amd64-netboot/base.sh +1 -1
  34. data/templates/Debian-7.2.0-i386-netboot/base.sh +1 -1
  35. data/templates/Debian-7.3.0-amd64-netboot/base.sh +1 -1
  36. data/templates/Debian-7.3.0-i386-netboot/base.sh +1 -1
  37. data/templates/Debian-7.4.0-amd64-netboot/base.sh +1 -1
  38. data/templates/Debian-7.4.0-i386-netboot/base.sh +1 -1
  39. data/templates/Debian-7.5.0-amd64-netboot/base.sh +1 -1
  40. data/templates/Debian-7.5.0-i386-netboot/base.sh +1 -1
  41. data/templates/Debian-7.6.0-amd64-netboot/base.sh +1 -1
  42. data/templates/Debian-7.6.0-i386-netboot/base.sh +1 -1
  43. data/templates/Debian-7.7.0-amd64-netboot/base.sh +25 -0
  44. data/templates/Debian-7.7.0-amd64-netboot/chef.sh +49 -0
  45. data/templates/Debian-7.7.0-amd64-netboot/cleanup.sh +18 -0
  46. data/templates/Debian-7.7.0-amd64-netboot/definition.rb +52 -0
  47. data/templates/Debian-7.7.0-amd64-netboot/preseed.cfg +313 -0
  48. data/templates/Debian-7.7.0-amd64-netboot/puppet.sh +7 -0
  49. data/templates/Debian-7.7.0-amd64-netboot/ruby.sh +10 -0
  50. data/templates/Debian-7.7.0-amd64-netboot/vagrant.sh +21 -0
  51. data/templates/Debian-7.7.0-amd64-netboot/virtualbox.sh +37 -0
  52. data/templates/Debian-7.7.0-amd64-netboot/vmfusion.sh +7 -0
  53. data/templates/{CentOS-5.10-i386 → Debian-7.7.0-amd64-netboot}/zerodisk.sh +0 -1
  54. data/templates/kali-1.0.9a-amd64/base.sh +1 -1
  55. data/templates/ubuntu-12.04.2-server-amd64/base.sh +1 -1
  56. data/templates/ubuntu-12.04.3-server-amd64-parallels/base.sh +1 -1
  57. data/templates/ubuntu-12.04.3-server-amd64/base.sh +1 -1
  58. data/test/build_realtest.rb +3 -3
  59. data/test/definitions/erb_definition/autorun0.erb +8 -0
  60. data/test/definitions/erb_definition/definition.rb +24 -0
  61. data/test/veewee/provider/core/helper/web_test.rb +30 -0
  62. metadata +31 -42
  63. data/templates/CentOS-5.10-i386-netboot/definition.rb +0 -42
  64. data/templates/CentOS-5.10-i386-netboot/ks.cfg +0 -27
  65. data/templates/CentOS-5.10-i386/base.sh +0 -8
  66. data/templates/CentOS-5.10-i386/chef.sh +0 -3
  67. data/templates/CentOS-5.10-i386/cleanup.sh +0 -11
  68. data/templates/CentOS-5.10-i386/definition.rb +0 -42
  69. data/templates/CentOS-5.10-i386/ks.cfg +0 -27
  70. data/templates/CentOS-5.10-i386/puppet.sh +0 -17
  71. data/templates/CentOS-5.10-i386/ruby.sh +0 -41
  72. data/templates/CentOS-5.10-i386/vagrant.sh +0 -9
  73. data/templates/CentOS-5.10-i386/virtualbox.sh +0 -9
  74. data/templates/CentOS-5.10-x86_64-netboot/base.sh +0 -8
  75. data/templates/CentOS-5.10-x86_64-netboot/chef.sh +0 -3
  76. data/templates/CentOS-5.10-x86_64-netboot/cleanup.sh +0 -11
  77. data/templates/CentOS-5.10-x86_64-netboot/definition.rb +0 -42
  78. data/templates/CentOS-5.10-x86_64-netboot/puppet.sh +0 -17
  79. data/templates/CentOS-5.10-x86_64-netboot/ruby.sh +0 -41
  80. data/templates/CentOS-5.10-x86_64-netboot/vagrant.sh +0 -9
  81. data/templates/CentOS-5.10-x86_64-netboot/virtualbox.sh +0 -9
  82. data/templates/CentOS-5.10-x86_64-netboot/zerodisk.sh +0 -4
  83. data/templates/CentOS-5.10-x86_64/base.sh +0 -8
  84. data/templates/CentOS-5.10-x86_64/chef.sh +0 -3
  85. data/templates/CentOS-5.10-x86_64/cleanup.sh +0 -11
  86. data/templates/CentOS-5.10-x86_64/definition.rb +0 -42
  87. data/templates/CentOS-5.10-x86_64/ks.cfg +0 -27
  88. data/templates/CentOS-5.10-x86_64/puppet.sh +0 -17
  89. data/templates/CentOS-5.10-x86_64/ruby.sh +0 -41
  90. data/templates/CentOS-5.10-x86_64/vagrant.sh +0 -9
  91. data/templates/CentOS-5.10-x86_64/virtualbox.sh +0 -9
  92. data/templates/CentOS-5.10-x86_64/zerodisk.sh +0 -4
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- MDgwZThlZDY5ZTBmZDFhZDVjYjQ3YzRmMjFlY2NmNzBiMmZlYTMyMg==
4
+ MmRmYjkxYTYyOGFhY2Y3ZmE5ZDNhYWZhODE0YWQyOTkwZTVlYTRmMA==
5
5
  data.tar.gz: !binary |-
6
- ZmEwZTc3MTc4OGFiY2IzZDZjOWQ4ODc4ZmQ4NDMwMmY0NjhlOTQyNQ==
6
+ ZDJjNGQ2YTRkY2RkZGJiOTQzNjA3MzcwNWQ0ZjUyMzVhZWNkMzViNg==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- MzNlYTg0YTIyN2JjYWZmMDdkMzAxMTdmNmI4ZGVjNGM0NmRhMmU3NWY3YjUw
10
- NjMwM2M3ZWY4OWJlYzg2ZTRhYTU0MzgzMmE0NGFlMzc4MTA2ZmU2NGE1M2Nk
11
- NDUyNTNhZjBkZTJhZjhkOGU5YWYxMjkyYjM0OWMzMjc5NmIzYTA=
9
+ NmY2MDQyODIwMzIwMmUyMmI0OTg1MWI2NjkwNTg1YmNmMGM0NjcyMTJkZTA0
10
+ ZWE2ODA2ODA4ZGMxYmVjMzE1ZWM4MDAwOGE4MGVmMjMxM2RkNTE5MTZhZTY3
11
+ MDdhMjE3NGEyYjcwNDgxOTU2Y2I0ZTBhMGQzOGU3YTIzYjI5Mzk=
12
12
  data.tar.gz: !binary |-
13
- Y2Q4ZjE4MDJkZThlYTM0YTU2MDcyMmI4M2NhOWM0OWRiMzM0MmU5YzllYjNi
14
- OGI1OTAzZDIwMTIwZDBlMzZkZjE4YTI3NmZmMzM0Y2UzM2JhZGZjZTMxMTRi
15
- NGM1YTM4YjhhMGRmYTU0MDk1MGY2NzBlYjg1NGY0NDQ2OThhNzA=
13
+ OTcyMWE1M2RmYjg1MzM2YmFmMTFjZDNmOWMxYTJmNzM4YjQzMmJjYjFkZjdl
14
+ YWJiOWJjNWJlNWYxZmQ5N2I1NjVjYmZjNjBhOGExOGE3YWEwNWQxNzA3Y2Rh
15
+ MmZkOWU4ZmY4MmRjNWY4MDMxZGRmYWJiMGJlOThhMWQ2YjNmZGM=
data/Gemfile CHANGED
@@ -3,7 +3,7 @@
3
3
  #Encoding.default_internal = Encoding::UTF_8
4
4
  #end
5
5
 
6
- source "http://rubygems.org"
6
+ source "https://rubygems.org"
7
7
 
8
8
  #gem "veewee", :path => "."
9
9
  #gem "fission", :path => '/Users/patrick/dev/fission'
@@ -43,16 +43,20 @@ module Veewee
43
43
  #consider proxy env vars only if host is not excluded
44
44
  :proxy => !no_proxy?(uri.host)
45
45
  ) { |src|
46
- # We assume large 10K files, so this is tempfile object
47
- env.logger.info "#{src.class}"
46
+ if
47
+ src.methods(&:to_sym).include?(:path)
48
+ then
49
+ # We assume large 10K files, so this is tempfile object
48
50
  ui.info "Moving #{src.path} to #{localfile}"
49
51
  # Force the close of the src stream to release handle before moving
50
52
  # Not forcing the close may cause an issue on windows (Permission Denied)
51
53
  src.close
52
54
  FileUtils.mv(src.path,localfile)
53
- #open(localfile,"wb") { |dst|
54
- #dst.write(src.read)
55
- #}
55
+ else
56
+ open(localfile,"wb") { |dst|
57
+ dst.write(src.read)
58
+ }
59
+ end
56
60
  }
57
61
  end
58
62
 
@@ -4,5 +4,5 @@ end
4
4
 
5
5
  # Only set the version constant if it wasn't set before
6
6
  unless defined?(Veewee::VERSION)
7
- ::Veewee::VERSION="0.5.0.alpha1"
7
+ ::Veewee::VERSION="0.5.0.alpha2"
8
8
  end
@@ -0,0 +1,5 @@
1
+ ---
2
+ :os_type_id: 'RedHat'
3
+ :iso_file: "CentOS-5.10-i386-bin-DVD-1of2.iso"
4
+ :iso_src: "http://mirrors.kernel.org/centos/5.10/isos/i386/CentOS-5.10-i386-bin-DVD-1of2.iso"
5
+ :iso_md5: "ec0acc2a4f6a813ea85bf1e36acb03f0"
@@ -0,0 +1,5 @@
1
+ ---
2
+ :os_type_id: 'RedHat'
3
+ :iso_file: "CentOS-5.10-i386-netinstall.iso"
4
+ :iso_src: "http://mirrors.kernel.org/centos/5.10/isos/i386/CentOS-5.10-i386-netinstall.iso"
5
+ :iso_md5: "8d19b12cb5f65a4b5c2bc61a98abf80c"
@@ -0,0 +1,5 @@
1
+ ---
2
+ :os_type_id: 'RedHat_64'
3
+ :iso_file: "CentOS-5.10-x86_64-bin-DVD-1of2.iso"
4
+ :iso_src: "http://mirrors.kernel.org/centos/5.10/isos/x86_64/CentOS-5.10-x86_64-bin-DVD-1of2.iso"
5
+ :iso_md5: "715f7355074c00530cd6ee1d9f43cc3f"
@@ -0,0 +1,5 @@
1
+ ---
2
+ :os_type_id: 'RedHat_64'
3
+ :iso_file: "CentOS-5.10-x86_64-netinstall.iso"
4
+ :iso_src: "http://mirrors.kernel.org/centos/5.10/isos/x86_64/CentOS-5.10-x86_64-netinstall.iso"
5
+ :iso_md5: "e09e44f04f0a4b97b04935e0ba88833f"
@@ -0,0 +1,5 @@
1
+ #
2
+ # change centos_64_dvd to one of configurations in *.yml in this directory
3
+ # use the yml files to configure
4
+ #
5
+ Veewee::Definition.declare_yaml('definition.yml', "centos_64_dvd.yml")
@@ -0,0 +1,35 @@
1
+ ---
2
+ :cpu_count: '1'
3
+ :memory_size: '384'
4
+ :disk_size: '10140'
5
+ :disk_format: 'VDI'
6
+ :hostiocache: 'on'
7
+ :virtualbox:
8
+ :vm_options:
9
+ "pae": "on"
10
+ "ioapic": "on"
11
+ :iso_download_timeout: 1000
12
+ :boot_wait: "10"
13
+ :boot_cmd_sequence:
14
+ - 'linux text ks=http://%IP%:%PORT%/ks.cfg<Enter>'
15
+ :kickstart_port: "7122"
16
+ :kickstart_timeout: 300
17
+ :kickstart_file: "ks.cfg"
18
+ :ssh_login_timeout: "10000"
19
+ :ssh_user: "vagrant"
20
+ :ssh_password: "vagrant"
21
+ :ssh_key: ""
22
+ :ssh_host_port: "7222"
23
+ :ssh_guest_port: "22"
24
+ :sudo_cmd: "echo '%p'|sudo -S sh '%f'"
25
+ :shutdown_cmd: "/sbin/halt -h -p"
26
+ :postinstall_files:
27
+ - "base.sh"
28
+ - "ruby.sh"
29
+ - "chef.sh"
30
+ - "puppet.sh"
31
+ - "vagrant.sh"
32
+ - "virtualbox.sh"
33
+ - "cleanup.sh"
34
+ - "zerodisk.sh"
35
+ :postinstall_timeout: 10000
@@ -1,5 +1,11 @@
1
1
  install
2
+ <% if definition.iso_file =~ /DVD/ %>
3
+ cdrom
4
+ <% elsif definition.os_type_id == "RedHat" %>
5
+ url --url=http://mirrors.kernel.org/centos/5.10/os/i386/
6
+ <% else %>
2
7
  url --url=http://mirrors.kernel.org/centos/5.10/os/x86_64/
8
+ <% end %>
3
9
  lang en_US.UTF-8
4
10
  langsupport --default=en_US.UTF-8 en_US.UTF-8
5
11
  keyboard us
@@ -6,7 +6,7 @@ apt-get clean
6
6
 
7
7
  #Setting up sudo
8
8
  cp /etc/sudoers /etc/sudoers.orig
9
- sed -i -e 's/vagrant ALL=(ALL) ALL/vagrant ALL=NOPASSWD:ALL/g' /etc/sudoers
9
+ sed -i -e 's/vagrant ALL=(ALL) ALL/vagrant ALL=(ALL) NOPASSWD: ALL/g' /etc/sudoers
10
10
 
11
11
  # Tweak sshd to prevent DNS resolution (speed up logins)
12
12
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -4,7 +4,7 @@ date > /etc/vagrant_box_build_time
4
4
 
5
5
  #Setting up sudo
6
6
  cp /etc/sudoers /etc/sudoers.orig
7
- sed -i -e 's/vagrant ALL=(ALL) ALL/vagrant ALL=NOPASSWD:ALL/g' /etc/sudoers
7
+ sed -i -e 's/vagrant ALL=(ALL) ALL/vagrant ALL=(ALL) NOPASSWD: ALL/g' /etc/sudoers
8
8
 
9
9
  #Installing vagrant keys
10
10
  mkdir /home/vagrant/.ssh
@@ -6,7 +6,7 @@ apt-get clean
6
6
 
7
7
  #Setting up sudo
8
8
  cp /etc/sudoers /etc/sudoers.orig
9
- sed -i -e 's/vagrant ALL=(ALL) ALL/vagrant ALL=NOPASSWD:ALL/g' /etc/sudoers
9
+ sed -i -e 's/vagrant ALL=(ALL) ALL/vagrant ALL=(ALL) NOPASSWD: ALL/g' /etc/sudoers
10
10
 
11
11
  # Tweak sshd to prevent DNS resolution (speed up logins)
12
12
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -4,7 +4,7 @@ date > /etc/vagrant_box_build_time
4
4
 
5
5
  #Setting up sudo
6
6
  cp /etc/sudoers /etc/sudoers.orig
7
- sed -i -e 's/vagrant ALL=(ALL) ALL/vagrant ALL=NOPASSWD:ALL/g' /etc/sudoers
7
+ sed -i -e 's/vagrant ALL=(ALL) ALL/vagrant ALL=(ALL) NOPASSWD: ALL/g' /etc/sudoers
8
8
 
9
9
  #Installing vagrant keys
10
10
  mkdir /home/vagrant/.ssh
@@ -6,7 +6,7 @@ apt-get clean
6
6
 
7
7
  #Setting up sudo
8
8
  cp /etc/sudoers /etc/sudoers.orig
9
- sed -i -e 's/vagrant ALL=(ALL) ALL/vagrant ALL=NOPASSWD:ALL/g' /etc/sudoers
9
+ sed -i -e 's/vagrant ALL=(ALL) ALL/vagrant ALL=(ALL) NOPASSWD: ALL/g' /etc/sudoers
10
10
 
11
11
  # Tweak sshd to prevent DNS resolution (speed up logins)
12
12
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -4,7 +4,7 @@ date > /etc/vagrant_box_build_time
4
4
 
5
5
  #Setting up sudo
6
6
  cp /etc/sudoers /etc/sudoers.orig
7
- sed -i -e 's/vagrant ALL=(ALL) ALL/vagrant ALL=NOPASSWD:ALL/g' /etc/sudoers
7
+ sed -i -e 's/vagrant ALL=(ALL) ALL/vagrant ALL=(ALL) NOPASSWD: ALL/g' /etc/sudoers
8
8
 
9
9
  #Installing vagrant keys
10
10
  mkdir /home/vagrant/.ssh
@@ -6,7 +6,7 @@ apt-get clean
6
6
 
7
7
  #Setting up sudo
8
8
  cp /etc/sudoers /etc/sudoers.orig
9
- sed -i -e 's/vagrant ALL=(ALL) ALL/vagrant ALL=NOPASSWD:ALL/g' /etc/sudoers
9
+ sed -i -e 's/vagrant ALL=(ALL) ALL/vagrant ALL=(ALL) NOPASSWD: ALL/g' /etc/sudoers
10
10
 
11
11
  # Tweak sshd to prevent DNS resolution (speed up logins)
12
12
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -4,7 +4,7 @@ date > /etc/vagrant_box_build_time
4
4
 
5
5
  #Setting up sudo
6
6
  cp /etc/sudoers /etc/sudoers.orig
7
- sed -i -e 's/vagrant ALL=(ALL) ALL/vagrant ALL=NOPASSWD:ALL/g' /etc/sudoers
7
+ sed -i -e 's/vagrant ALL=(ALL) ALL/vagrant ALL=(ALL) NOPASSWD: ALL/g' /etc/sudoers
8
8
 
9
9
  #Installing vagrant keys
10
10
  mkdir /home/vagrant/.ssh
@@ -7,7 +7,7 @@ apt-get clean
7
7
 
8
8
  # Set up sudo
9
9
  ( cat <<'EOP'
10
- %vagrant ALL=NOPASSWD:ALL
10
+ %vagrant ALL=(ALL) NOPASSWD: ALL
11
11
  EOP
12
12
  ) > /tmp/vagrant
13
13
  chmod 0440 /tmp/vagrant
@@ -6,7 +6,7 @@ apt-get -y install zlib1g-dev libssl-dev libreadline-gplv2-dev
6
6
  apt-get -y install curl unzip
7
7
 
8
8
  # Set up sudo
9
- echo 'vagrant ALL=NOPASSWD:ALL' > /etc/sudoers.d/vagrant
9
+ echo 'vagrant ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/vagrant
10
10
 
11
11
  # Tweak sshd to prevent DNS resolution (speed up logins)
12
12
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -7,7 +7,7 @@ apt-get -y install curl unzip
7
7
  apt-get clean
8
8
 
9
9
  # Set up sudo
10
- echo 'vagrant ALL=NOPASSWD:ALL' > /etc/sudoers.d/vagrant
10
+ echo 'vagrant ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/vagrant
11
11
 
12
12
  # Tweak sshd to prevent DNS resolution (speed up logins)
13
13
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -6,7 +6,7 @@ apt-get -y install zlib1g-dev libssl-dev libreadline-gplv2-dev
6
6
  apt-get -y install curl unzip
7
7
 
8
8
  # Set up sudo
9
- echo 'vagrant ALL=NOPASSWD:ALL' > /etc/sudoers.d/vagrant
9
+ echo 'vagrant ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/vagrant
10
10
 
11
11
  # Tweak sshd to prevent DNS resolution (speed up logins)
12
12
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -7,7 +7,7 @@ apt-get -y install curl unzip
7
7
  apt-get clean
8
8
 
9
9
  # Set up sudo
10
- echo 'vagrant ALL=NOPASSWD:ALL' > /etc/sudoers.d/vagrant
10
+ echo 'vagrant ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/vagrant
11
11
 
12
12
  # Tweak sshd to prevent DNS resolution (speed up logins)
13
13
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -6,7 +6,7 @@ apt-get -y install zlib1g-dev libssl-dev libreadline-gplv2-dev
6
6
  apt-get -y install curl unzip
7
7
 
8
8
  # Set up sudo
9
- echo 'vagrant ALL=NOPASSWD:ALL' > /etc/sudoers.d/vagrant
9
+ echo 'vagrant ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/vagrant
10
10
 
11
11
  # Tweak sshd to prevent DNS resolution (speed up logins)
12
12
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -7,7 +7,7 @@ apt-get -y install curl unzip
7
7
  apt-get clean
8
8
 
9
9
  # Set up sudo
10
- echo 'vagrant ALL=NOPASSWD:ALL' > /etc/sudoers.d/vagrant
10
+ echo 'vagrant ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/vagrant
11
11
 
12
12
  # Tweak sshd to prevent DNS resolution (speed up logins)
13
13
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -6,7 +6,7 @@ apt-get -y install zlib1g-dev libssl-dev libreadline-gplv2-dev
6
6
  apt-get -y install curl unzip
7
7
 
8
8
  # Set up sudo
9
- echo 'vagrant ALL=NOPASSWD:ALL' > /etc/sudoers.d/vagrant
9
+ echo 'vagrant ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/vagrant
10
10
 
11
11
  # Tweak sshd to prevent DNS resolution (speed up logins)
12
12
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -7,7 +7,7 @@ apt-get -y install curl unzip
7
7
  apt-get clean
8
8
 
9
9
  # Set up sudo
10
- echo 'vagrant ALL=NOPASSWD:ALL' > /etc/sudoers.d/vagrant
10
+ echo 'vagrant ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/vagrant
11
11
 
12
12
  # Tweak sshd to prevent DNS resolution (speed up logins)
13
13
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -6,7 +6,7 @@ apt-get -y install zlib1g-dev libssl-dev libreadline-gplv2-dev
6
6
  apt-get -y install curl unzip
7
7
 
8
8
  # Set up sudo
9
- echo 'vagrant ALL=NOPASSWD:ALL' > /etc/sudoers.d/vagrant
9
+ echo 'vagrant ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/vagrant
10
10
 
11
11
  # Tweak sshd to prevent DNS resolution (speed up logins)
12
12
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -7,7 +7,7 @@ apt-get -y install curl unzip
7
7
  apt-get clean
8
8
 
9
9
  # Set up sudo
10
- echo 'vagrant ALL=NOPASSWD:ALL' > /etc/sudoers.d/vagrant
10
+ echo 'vagrant ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/vagrant
11
11
 
12
12
  # Tweak sshd to prevent DNS resolution (speed up logins)
13
13
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -5,7 +5,7 @@ apt-get -y install zlib1g-dev libssl-dev libreadline-gplv2-dev
5
5
  apt-get -y install curl unzip
6
6
 
7
7
  # Set up sudo
8
- echo 'vagrant ALL=NOPASSWD:ALL' > /etc/sudoers.d/vagrant
8
+ echo 'vagrant ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/vagrant
9
9
 
10
10
  # Tweak sshd to prevent DNS resolution (speed up logins)
11
11
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -6,7 +6,7 @@ apt-get -y install curl unzip
6
6
  apt-get clean
7
7
 
8
8
  # Set up sudo
9
- echo 'vagrant ALL=NOPASSWD:ALL' > /etc/sudoers.d/vagrant
9
+ echo 'vagrant ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/vagrant
10
10
 
11
11
  # Tweak sshd to prevent DNS resolution (speed up logins)
12
12
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -5,7 +5,7 @@ apt-get -y install zlib1g-dev libssl-dev libreadline-gplv2-dev
5
5
  apt-get -y install curl unzip
6
6
 
7
7
  # Set up sudo
8
- echo 'vagrant ALL=NOPASSWD:ALL' > /etc/sudoers.d/vagrant
8
+ echo 'vagrant ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/vagrant
9
9
 
10
10
  # Tweak sshd to prevent DNS resolution (speed up logins)
11
11
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -6,7 +6,7 @@ apt-get -y install curl unzip
6
6
  apt-get clean
7
7
 
8
8
  # Set up sudo
9
- echo 'vagrant ALL=NOPASSWD:ALL' > /etc/sudoers.d/vagrant
9
+ echo 'vagrant ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/vagrant
10
10
 
11
11
  # Tweak sshd to prevent DNS resolution (speed up logins)
12
12
  echo 'UseDNS no' >> /etc/ssh/sshd_config
@@ -0,0 +1,25 @@
1
+ # Update the box
2
+ apt-get -y update
3
+ apt-get -y install linux-headers-$(uname -r) build-essential
4
+ apt-get -y install zlib1g-dev libssl-dev libreadline-gplv2-dev
5
+ apt-get -y install curl unzip
6
+
7
+ # Set up sudo
8
+ echo 'vagrant ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/vagrant
9
+
10
+ # Tweak sshd to prevent DNS resolution (speed up logins)
11
+ echo 'UseDNS no' >> /etc/ssh/sshd_config
12
+
13
+ # Remove 5s grub timeout to speed up booting
14
+ cat <<EOF > /etc/default/grub
15
+ # If you change this file, run 'update-grub' afterwards to update
16
+ # /boot/grub/grub.cfg.
17
+
18
+ GRUB_DEFAULT=0
19
+ GRUB_TIMEOUT=0
20
+ GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
21
+ GRUB_CMDLINE_LINUX_DEFAULT="quiet"
22
+ GRUB_CMDLINE_LINUX="debian-installer=en_US"
23
+ EOF
24
+
25
+ update-grub
@@ -0,0 +1,49 @@
1
+ if [ -f .veewee_params ]
2
+ then
3
+ . .veewee_params
4
+ fi
5
+
6
+ # Default to Gem install
7
+ if [ -z "$CHEF_INSTALLMETHOD" ]; then
8
+ export CHEF_INSTALLMETHOD="gems"
9
+ fi
10
+
11
+ # Installing chef
12
+ case $CHEF_INSTALLMETHOD in
13
+ "gems")
14
+ # Using gems
15
+ if [ -z "$CHEF_VERSION" ]; then
16
+ # Default to latest
17
+ gem install chef --no-ri --no-rdoc
18
+ else
19
+ gem install chef --no-ri --no-rdoc --version $CHEF_VERSION
20
+ fi
21
+ ;;
22
+
23
+ "omnibus")
24
+ # Using omnibus
25
+ if [ -z "$CHEF_VERSION" ]; then
26
+ # Default to latest
27
+ wget -O - http://opscode.com/chef/install.sh | sudo bash -s
28
+ else
29
+ wget -O - http://opscode.com/chef/install.sh | sudo bash -s -- -v $CHEF_VERSION
30
+ fi
31
+ ;;
32
+
33
+ "package")
34
+ # Using packages
35
+ apt-get install -y debconf-utils
36
+ echo "chef chef/chef_server_url string $CHEF_SERVER_URL" | debconf-set-selections
37
+ if [ -z "$CHEF_VERSION" ]; then
38
+ # Default to latest
39
+ apt-get install -y chef
40
+ else
41
+ apt-get install -y chef=$CHEF_VERSION
42
+ fi
43
+ ;;
44
+
45
+ *)
46
+ echo "Unsupported method for installing chef"
47
+ exit -1
48
+ ;;
49
+ esac