vbox 0.0.4
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.
- data/.gitignore +14 -0
- data/Gemfile +5 -0
- data/Gemfile.lock +68 -0
- data/README.md +5 -0
- data/Rakefile +91 -0
- data/bin/vbox +73 -0
- data/lib/java/README.txt +5 -0
- data/lib/java/dir2floppy.jar +0 -0
- data/lib/java/dir2floppy.java +134 -0
- data/lib/vagrant_init.rb +6 -0
- data/lib/vbox.rb +2 -0
- data/lib/vbox/command.rb +82 -0
- data/lib/vbox/config.rb +5 -0
- data/lib/vbox/export.rb +65 -0
- data/lib/vbox/scancode.rb +208 -0
- data/lib/vbox/session.rb +893 -0
- data/lib/vbox/shell.rb +54 -0
- data/lib/vbox/ssh.rb +193 -0
- data/lib/vbox/transaction.rb +122 -0
- data/lib/vbox/utils.rb +26 -0
- data/lib/vbox/version.rb +3 -0
- data/lib/vbox/web.rb +48 -0
- data/templates/CentOS-5.7-i386-netboot/definition.rb +16 -0
- data/templates/CentOS-5.7-i386-netboot/ks.cfg +45 -0
- data/templates/CentOS-5.7-i386-netboot/postinstall.sh +53 -0
- data/templates/CentOS-5.7-x86_64-netboot/definition.rb +16 -0
- data/templates/CentOS-5.7-x86_64-netboot/ks.cfg +45 -0
- data/templates/CentOS-5.7-x86_64-netboot/postinstall.sh +60 -0
- data/templates/CentOS-6.0-i386-netboot/definition.rb +16 -0
- data/templates/CentOS-6.0-i386-netboot/ks.cfg +52 -0
- data/templates/CentOS-6.0-i386-netboot/postinstall.sh +30 -0
- data/templates/CentOS-6.0-i386/definition.rb +17 -0
- data/templates/CentOS-6.0-i386/ks.cfg +47 -0
- data/templates/CentOS-6.0-i386/postinstall.sh +48 -0
- data/templates/CentOS-6.0-x86_64-netboot/definition.rb +16 -0
- data/templates/CentOS-6.0-x86_64-netboot/ks.cfg +52 -0
- data/templates/CentOS-6.0-x86_64-netboot/postinstall.sh +30 -0
- data/templates/CentOS-6.0-x86_64/definition.rb +17 -0
- data/templates/CentOS-6.0-x86_64/ks.cfg +47 -0
- data/templates/CentOS-6.0-x86_64/postinstall.sh +48 -0
- data/templates/Debian-6.0.3-amd64-netboot/definition.rb +42 -0
- data/templates/Debian-6.0.3-amd64-netboot/postinstall.sh +80 -0
- data/templates/Debian-6.0.3-amd64-netboot/preseed.cfg +42 -0
- data/templates/Debian-6.0.3-i386-netboot/definition.rb +44 -0
- data/templates/Debian-6.0.3-i386-netboot/postinstall.sh +80 -0
- data/templates/Debian-6.0.3-i386-netboot/preseed.cfg +42 -0
- data/templates/Fedora-15-i386-netboot/definition.rb +17 -0
- data/templates/Fedora-15-i386-netboot/ks.cfg +82 -0
- data/templates/Fedora-15-i386-netboot/postinstall.sh +18 -0
- data/templates/Fedora-15-i386/definition.rb +17 -0
- data/templates/Fedora-15-i386/ks.cfg +64 -0
- data/templates/Fedora-15-i386/postinstall.sh +33 -0
- data/templates/Fedora-15-x86_64-netboot/definition.rb +29 -0
- data/templates/Fedora-15-x86_64-netboot/ks.cfg +64 -0
- data/templates/Fedora-15-x86_64-netboot/postinstall.sh +33 -0
- data/templates/Fedora-15-x86_64/definition.rb +17 -0
- data/templates/Fedora-15-x86_64/ks.cfg +64 -0
- data/templates/Fedora-15-x86_64/postinstall.sh +33 -0
- data/templates/Sysrescuecd-2.0.0-experimental/autorun0 +3 -0
- data/templates/Sysrescuecd-2.0.0-experimental/definition.rb +20 -0
- data/templates/archlinux-i386-netboot/aif.cfg +34 -0
- data/templates/archlinux-i386-netboot/definition.rb +29 -0
- data/templates/archlinux-i386-netboot/postinstall.sh +87 -0
- data/templates/archlinux-i386-netboot/postinstall2.sh +28 -0
- data/templates/archlinux-i386/aif.cfg +33 -0
- data/templates/archlinux-i386/definition.rb +29 -0
- data/templates/archlinux-i386/postinstall.sh +106 -0
- data/templates/archlinux-x86_64-netboot/aif.cfg +34 -0
- data/templates/archlinux-x86_64-netboot/definition.rb +29 -0
- data/templates/archlinux-x86_64-netboot/postinstall.sh +90 -0
- data/templates/archlinux-x86_64-netboot/postinstall2.sh +28 -0
- data/templates/archlinux-x86_64/aif.cfg +33 -0
- data/templates/archlinux-x86_64/definition.rb +29 -0
- data/templates/archlinux-x86_64/postinstall.sh +90 -0
- data/templates/archlinux-x86_64/postinstall2.sh +38 -0
- data/templates/freebsd-8.2-experimental/definition.rb +19 -0
- data/templates/freebsd-8.2-experimental/postinstall.sh +191 -0
- data/templates/freebsd-8.2-pcbsd-i386-netboot/definition.rb +35 -0
- data/templates/freebsd-8.2-pcbsd-i386-netboot/pcinstall.fbg.cfg +58 -0
- data/templates/freebsd-8.2-pcbsd-i386-netboot/postinstall.sh +93 -0
- data/templates/freebsd-8.2-pcbsd-i386/definition.rb +31 -0
- data/templates/freebsd-8.2-pcbsd-i386/pcinstall.fbg.cfg +57 -0
- data/templates/freebsd-8.2-pcbsd-i386/postinstall.sh +93 -0
- data/templates/gentoo-latest-i386-experimental/definition.rb +29 -0
- data/templates/gentoo-latest-i386-experimental/postinstall.sh +184 -0
- data/templates/openSUSE-11.4-DVD-i586/autoinst_de.xml +1284 -0
- data/templates/openSUSE-11.4-DVD-i586/autoinst_en.xml +1284 -0
- data/templates/openSUSE-11.4-DVD-i586/definition.rb +28 -0
- data/templates/openSUSE-11.4-DVD-i586/postinstall.sh +43 -0
- data/templates/openSUSE-11.4-DVD-x86_64/autoinst_de.xml +1459 -0
- data/templates/openSUSE-11.4-DVD-x86_64/autoinst_en.xml +1459 -0
- data/templates/openSUSE-11.4-DVD-x86_64/definition.rb +28 -0
- data/templates/openSUSE-11.4-DVD-x86_64/postinstall.sh +43 -0
- data/templates/openSUSE-11.4-NET-i586/autoinst_de.xml +1278 -0
- data/templates/openSUSE-11.4-NET-i586/autoinst_en.xml +1278 -0
- data/templates/openSUSE-11.4-NET-i586/definition.rb +28 -0
- data/templates/openSUSE-11.4-NET-i586/postinstall.sh +43 -0
- data/templates/openSUSE-11.4-NET-x86_64/autoinst_de.xml +1453 -0
- data/templates/openSUSE-11.4-NET-x86_64/autoinst_en.xml +1453 -0
- data/templates/openSUSE-11.4-NET-x86_64/definition.rb +28 -0
- data/templates/openSUSE-11.4-NET-x86_64/postinstall.sh +43 -0
- data/templates/solaris-11-express-i386/auto_install/ai.dtd +58 -0
- data/templates/solaris-11-express-i386/auto_install/ai_manifest.xml +241 -0
- data/templates/solaris-11-express-i386/auto_install/configuration.dtd +44 -0
- data/templates/solaris-11-express-i386/auto_install/default.xml +124 -0
- data/templates/solaris-11-express-i386/auto_install/default.xml.orig +124 -0
- data/templates/solaris-11-express-i386/auto_install/sc_profiles/static_network.xml +105 -0
- data/templates/solaris-11-express-i386/auto_install/software.dtd +105 -0
- data/templates/solaris-11-express-i386/auto_install/target.dtd +196 -0
- data/templates/solaris-11-express-i386/default.xml +121 -0
- data/templates/solaris-11-express-i386/definition.rb +65 -0
- data/templates/solaris-11-express-i386/postinstall.sh +98 -0
- data/templates/ubuntu-10.04.3-server-amd64/definition.rb +54 -0
- data/templates/ubuntu-10.04.3-server-amd64/postinstall.sh +90 -0
- data/templates/ubuntu-10.04.3-server-amd64/preseed.cfg +87 -0
- data/templates/ubuntu-10.04.3-server-i386/definition.rb +24 -0
- data/templates/ubuntu-10.04.3-server-i386/postinstall.sh +91 -0
- data/templates/ubuntu-10.04.3-server-i386/preseed.cfg +87 -0
- data/templates/ubuntu-11.10-server-amd64/definition.rb +35 -0
- data/templates/ubuntu-11.10-server-amd64/postinstall.sh +90 -0
- data/templates/ubuntu-11.10-server-amd64/preseed.cfg +87 -0
- data/templates/ubuntu-11.10-server-i386/definition.rb +35 -0
- data/templates/ubuntu-11.10-server-i386/postinstall.sh +90 -0
- data/templates/ubuntu-11.10-server-i386/preseed.cfg +87 -0
- data/validation/features/steps/ssh_steps.rb +169 -0
- data/validation/support/env.rb +1 -0
- data/validation/vagrant-private.key +27 -0
- data/validation/vagrant.feature +52 -0
- data/validation/vagrant.pub +1 -0
- data/vbox.gemspec +32 -0
- metadata +338 -0
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
d-i debian-installer/locale string en_US
|
|
2
|
+
d-i console-keymaps-at/keymap select us
|
|
3
|
+
d-i netcfg/choose_interface select auto
|
|
4
|
+
d-i netcfg/get_domain string vagrantup.com
|
|
5
|
+
d-i netcfg/wireless_wep string
|
|
6
|
+
d-i mirror/country string manual
|
|
7
|
+
d-i mirror/http/hostname string http.us.debian.org
|
|
8
|
+
d-i mirror/http/directory string /debian
|
|
9
|
+
d-i mirror/http/proxy string
|
|
10
|
+
d-i clock-setup/utc boolean true
|
|
11
|
+
d-i time/zone string UTC
|
|
12
|
+
d-i clock-setup/ntp boolean true
|
|
13
|
+
d-i partman-auto/disk string /dev/sda
|
|
14
|
+
d-i partman-auto/method string lvm
|
|
15
|
+
d-i partman-lvm/device_remove_lvm boolean true
|
|
16
|
+
d-i partman-md/device_remove_md boolean true
|
|
17
|
+
d-i partman-lvm/confirm boolean true
|
|
18
|
+
d-i partman-lvm/confirm_nooverwrite boolean true
|
|
19
|
+
d-i partman/choose_partition select finish
|
|
20
|
+
d-i partman-auto-lvm/guided_size string max
|
|
21
|
+
d-i partman-auto/choose_recipe select atomic
|
|
22
|
+
d-i partman/default_filesystem string ext3
|
|
23
|
+
d-i partman/confirm_write_new_label boolean true
|
|
24
|
+
d-i partman/confirm boolean true
|
|
25
|
+
d-i partman/confirm_nooverwrite boolean true
|
|
26
|
+
d-i passwd/root-login boolean false
|
|
27
|
+
d-i passwd/root-password password vagrant
|
|
28
|
+
d-i passwd/root-password-again password vagrant
|
|
29
|
+
d-i passwd/user-fullname string Vagrant User
|
|
30
|
+
d-i passwd/username string vagrant
|
|
31
|
+
d-i passwd/user-password password vagrant
|
|
32
|
+
d-i passwd/user-password-again password vagrant
|
|
33
|
+
d-i user-setup/encrypt-home boolean false
|
|
34
|
+
d-i user-setup/allow-password-weak boolean true
|
|
35
|
+
d-i passwd/user-default-groups string audio cdrom video admin
|
|
36
|
+
tasksel tasksel/first multiselect standard
|
|
37
|
+
d-i pkgsel/include string openssh-server ntp acpid sudo bzip2
|
|
38
|
+
d-i pkgsel/upgrade select none
|
|
39
|
+
popularity-contest popularity-contest/participate boolean false
|
|
40
|
+
d-i grub-installer/only_debian boolean true
|
|
41
|
+
d-i grub-installer/with_other_os boolean true
|
|
42
|
+
d-i finish-install/reboot_in_progress note
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
Veewee::Session.declare({
|
|
2
|
+
# Minimum RAM requirement for installation is 640MB.
|
|
3
|
+
:cpu_count => '1', :memory_size=> '640',
|
|
4
|
+
:disk_size => '10140', :disk_format => 'VDI', :hostiocache => 'off', :hwvirtext => 'on',
|
|
5
|
+
:os_type_id => 'Fedora',
|
|
6
|
+
:iso_file => "Fedora-15-i386-netinst.iso",
|
|
7
|
+
:iso_src => "http://download.fedoraproject.org/pub/fedora/linux/releases/15/Fedora/i386/iso/Fedora-15-i386-netinst.iso",
|
|
8
|
+
:iso_md5 => "9a91492ac84dde9ceff0cb346a079487",
|
|
9
|
+
:iso_download_timeout => 1000,
|
|
10
|
+
:boot_wait => "10", :boot_cmd_sequence => [ '<Tab> linux text ks=http://%IP%:%PORT%/ks.cfg<Enter><Enter>' ],
|
|
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",
|
|
14
|
+
:sudo_cmd => "echo '%p'|sudo -S sh '%f'",
|
|
15
|
+
:shutdown_cmd => "/sbin/halt -h -p",
|
|
16
|
+
:postinstall_files => [ "postinstall.sh"], :postinstall_timeout => 10000
|
|
17
|
+
})
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
# Kickstart file automatically generated by anaconda.
|
|
2
|
+
|
|
3
|
+
install
|
|
4
|
+
cdrom
|
|
5
|
+
lang en_US.UTF-8
|
|
6
|
+
keyboard us
|
|
7
|
+
network --onboot yes --device p2p1 --bootproto dhcp --noipv6
|
|
8
|
+
timezone --utc America/Los_Angeles
|
|
9
|
+
rootpw --iscrypted $6$n/NGsk5H2aiBMXL4$r/oPkJtB5rasvQHPo9AvIJBe6sNVlQbpZxvTRMN7.qZk/Sn9u2qZ0XgNxflUvK20y7OIWdr/vv7MED6gzkBiH0
|
|
10
|
+
selinux --enforcing
|
|
11
|
+
authconfig --enableshadow --passalgo=sha512
|
|
12
|
+
firewall --service=ssh
|
|
13
|
+
# The following is the partition information you requested
|
|
14
|
+
# Note that any partitions you deleted are not expressed
|
|
15
|
+
# here so unless you clear all partitions first, this is
|
|
16
|
+
# not guaranteed to work
|
|
17
|
+
clearpart --all --drives=sda --initlabel
|
|
18
|
+
|
|
19
|
+
part /boot --fstype=ext4 --size=500
|
|
20
|
+
part pv.2 --grow --size=500
|
|
21
|
+
|
|
22
|
+
volgroup vg_vagrant --pesize=32768 pv.2
|
|
23
|
+
logvol / --fstype=ext4 --name=lv_root --vgname=vg_vagrant --size=1024 --grow
|
|
24
|
+
logvol swap --fstype=swap --name=lv_swap --vgname=vg_vagrant --size=528 --grow --maxsize=1056
|
|
25
|
+
bootloader --location=mbr --driveorder=sda --append="norhgb"
|
|
26
|
+
repo --name="Fedora 15 - i386" --mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=fedora-15&arch=i386 --cost=1000
|
|
27
|
+
repo --name="Fedora 15 - i386 - Updates" --mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=updates-released-f15&arch=i386 --cost=1000
|
|
28
|
+
services --enabled network
|
|
29
|
+
reboot
|
|
30
|
+
|
|
31
|
+
%packages
|
|
32
|
+
@core
|
|
33
|
+
@online-docs
|
|
34
|
+
|
|
35
|
+
# Requirements for vagrant
|
|
36
|
+
kernel-PAE-devel
|
|
37
|
+
kernel-headers
|
|
38
|
+
make
|
|
39
|
+
gcc
|
|
40
|
+
|
|
41
|
+
# For puppet
|
|
42
|
+
puppet
|
|
43
|
+
|
|
44
|
+
# For Chef
|
|
45
|
+
ruby-devel
|
|
46
|
+
rubygems
|
|
47
|
+
rubygem-erubis
|
|
48
|
+
rubygem-highline
|
|
49
|
+
rubygem-json
|
|
50
|
+
rubygem-mime-types
|
|
51
|
+
rubygem-net-ssh
|
|
52
|
+
rubygem-polyglot
|
|
53
|
+
rubygem-rest-client
|
|
54
|
+
rubygem-treetop
|
|
55
|
+
rubygem-uuidtools
|
|
56
|
+
%end
|
|
57
|
+
|
|
58
|
+
%post
|
|
59
|
+
# Make ssh quicker in disconnected situations.
|
|
60
|
+
echo 'UseDNS no' >> /etc/ssh/sshd_config
|
|
61
|
+
|
|
62
|
+
# Add Vagrant user and group.
|
|
63
|
+
/usr/sbin/groupadd vagrant
|
|
64
|
+
/usr/sbin/useradd vagrant -g vagrant
|
|
65
|
+
echo "vagrant"|passwd --stdin vagrant
|
|
66
|
+
|
|
67
|
+
# Give Vagrant user permission to sudo.
|
|
68
|
+
echo 'Defaults:vagrant !requiretty' > /etc/sudoers.d/vagrant
|
|
69
|
+
echo '%vagrant ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers.d/vagrant
|
|
70
|
+
chmod 440 /etc/sudoers.d/vagrant
|
|
71
|
+
|
|
72
|
+
# Install chef.
|
|
73
|
+
gem install chef --no-ri --no-rdoc
|
|
74
|
+
|
|
75
|
+
# Install vagrant authorized ssh key.
|
|
76
|
+
mkdir /home/vagrant/.ssh
|
|
77
|
+
curl -L 'http://github.com/mitchellh/vagrant/raw/master/keys/vagrant.pub' > /home/vagrant/.ssh/authorized_keys
|
|
78
|
+
chown vagrant:vagrant -R /home/vagrant/.ssh
|
|
79
|
+
chmod 700 /home/vagrant/.ssh
|
|
80
|
+
chmod 600 /home/vagrant/.ssh/authorized_keys
|
|
81
|
+
chcon -R unconfined_u:object_r:user_home_t:s0 /home/vagrant/.ssh
|
|
82
|
+
%end
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
#!/bin/sh
|
|
2
|
+
|
|
3
|
+
date > /etc/vagrant_box_build_time
|
|
4
|
+
|
|
5
|
+
# Install VirtualBox extensions.
|
|
6
|
+
|
|
7
|
+
VBOX_VERSION=$(cat /home/vagrant/.vbox_version)
|
|
8
|
+
|
|
9
|
+
cd /tmp
|
|
10
|
+
wget http://download.virtualbox.org/virtualbox/$VBOX_VERSION/VBoxGuestAdditions_$VBOX_VERSION.iso
|
|
11
|
+
mount -o loop,ro VBoxGuestAdditions_$VBOX_VERSION.iso /mnt
|
|
12
|
+
sh /mnt/VBoxLinuxAdditions.run
|
|
13
|
+
umount /mnt
|
|
14
|
+
rm VBoxGuestAdditions_$VBOX_VERSION.iso
|
|
15
|
+
|
|
16
|
+
exit 0
|
|
17
|
+
|
|
18
|
+
# EOF
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
Veewee::Session.declare({
|
|
2
|
+
# Minimum RAM requirement for installation is 640MB.
|
|
3
|
+
:cpu_count => '1', :memory_size=> '640',
|
|
4
|
+
:disk_size => '10140', :disk_format => 'VDI', :hostiocache => 'off', :hwvirtext => 'on',
|
|
5
|
+
:os_type_id => 'Fedora',
|
|
6
|
+
:iso_file => "Fedora-15-i386-DVD.iso",
|
|
7
|
+
:iso_src => "http://download.fedoraproject.org/pub/fedora/linux/releases/15/Fedora/i386/iso/Fedora-15-i386-DVD.iso",
|
|
8
|
+
:iso_md5 => "eea96f0d780687a73fdbc78137b38584",
|
|
9
|
+
:iso_download_timeout => 1000,
|
|
10
|
+
:boot_wait => "10", :boot_cmd_sequence => [ '<Tab> linux text ks=http://%IP%:%PORT%/ks.cfg<Enter><Enter>' ],
|
|
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",
|
|
14
|
+
:sudo_cmd => "echo '%p'|sudo -S sh '%f'",
|
|
15
|
+
:shutdown_cmd => "/sbin/halt -h -p",
|
|
16
|
+
:postinstall_files => [ "postinstall.sh"], :postinstall_timeout => 10000
|
|
17
|
+
})
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
# Kickstart file automatically generated by anaconda.
|
|
2
|
+
|
|
3
|
+
install
|
|
4
|
+
cdrom
|
|
5
|
+
lang en_US.UTF-8
|
|
6
|
+
keyboard us
|
|
7
|
+
network --onboot yes --device p2p1 --bootproto dhcp --noipv6
|
|
8
|
+
timezone --utc America/Los_Angeles
|
|
9
|
+
rootpw --iscrypted $6$n/NGsk5H2aiBMXL4$r/oPkJtB5rasvQHPo9AvIJBe6sNVlQbpZxvTRMN7.qZk/Sn9u2qZ0XgNxflUvK20y7OIWdr/vv7MED6gzkBiH0
|
|
10
|
+
selinux --enforcing
|
|
11
|
+
authconfig --enableshadow --passalgo=sha512
|
|
12
|
+
firewall --service=ssh
|
|
13
|
+
# The following is the partition information you requested
|
|
14
|
+
# Note that any partitions you deleted are not expressed
|
|
15
|
+
# here so unless you clear all partitions first, this is
|
|
16
|
+
# not guaranteed to work
|
|
17
|
+
clearpart --all --drives=sda --initlabel
|
|
18
|
+
|
|
19
|
+
part /boot --fstype=ext4 --size=500
|
|
20
|
+
part pv.2 --grow --size=500
|
|
21
|
+
|
|
22
|
+
volgroup vg_vagrant --pesize=32768 pv.2
|
|
23
|
+
logvol / --fstype=ext4 --name=lv_root --vgname=vg_vagrant --size=1024 --grow
|
|
24
|
+
logvol swap --fstype=swap --name=lv_swap --vgname=vg_vagrant --size=528 --grow --maxsize=1056
|
|
25
|
+
bootloader --location=mbr --driveorder=sda --append="norhgb"
|
|
26
|
+
# Disable remote repositories, as this is a non-netinst install.
|
|
27
|
+
#repo --name="Fedora 15 - i386" --mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=fedora-15&arch=i386 --cost=1000
|
|
28
|
+
#repo --name="Fedora 15 - i386 - Updates" --mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=updates-released-f15&arch=i386 --cost=1000
|
|
29
|
+
services --enabled network
|
|
30
|
+
reboot
|
|
31
|
+
|
|
32
|
+
%packages
|
|
33
|
+
@core
|
|
34
|
+
@online-docs
|
|
35
|
+
|
|
36
|
+
# Requirements for vagrant
|
|
37
|
+
kernel-PAE-devel
|
|
38
|
+
kernel-headers
|
|
39
|
+
make
|
|
40
|
+
gcc
|
|
41
|
+
%end
|
|
42
|
+
|
|
43
|
+
%post
|
|
44
|
+
# Make ssh quicker in disconnected situations.
|
|
45
|
+
echo 'UseDNS no' >> /etc/ssh/sshd_config
|
|
46
|
+
|
|
47
|
+
# Add Vagrant user and group.
|
|
48
|
+
/usr/sbin/groupadd vagrant
|
|
49
|
+
/usr/sbin/useradd vagrant -g vagrant
|
|
50
|
+
echo "vagrant"|passwd --stdin vagrant
|
|
51
|
+
|
|
52
|
+
# Give Vagrant user permission to sudo.
|
|
53
|
+
echo 'Defaults:vagrant !requiretty' > /etc/sudoers.d/vagrant
|
|
54
|
+
echo '%vagrant ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers.d/vagrant
|
|
55
|
+
chmod 440 /etc/sudoers.d/vagrant
|
|
56
|
+
|
|
57
|
+
# Install vagrant authorized ssh key.
|
|
58
|
+
mkdir /home/vagrant/.ssh
|
|
59
|
+
curl -L 'http://github.com/mitchellh/vagrant/raw/master/keys/vagrant.pub' > /home/vagrant/.ssh/authorized_keys
|
|
60
|
+
chown vagrant:vagrant -R /home/vagrant/.ssh
|
|
61
|
+
chmod 700 /home/vagrant/.ssh
|
|
62
|
+
chmod 600 /home/vagrant/.ssh/authorized_keys
|
|
63
|
+
chcon -R unconfined_u:object_r:user_home_t:s0 /home/vagrant/.ssh
|
|
64
|
+
%end
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
#!/bin/sh
|
|
2
|
+
|
|
3
|
+
date > /etc/vagrant_box_build_time
|
|
4
|
+
|
|
5
|
+
VBOX_VERSION=$(cat /home/vagrant/.vbox_version)
|
|
6
|
+
|
|
7
|
+
yum -y install \
|
|
8
|
+
ruby \
|
|
9
|
+
ruby-devel \
|
|
10
|
+
puppet \
|
|
11
|
+
rubygems \
|
|
12
|
+
rubygem-erubis \
|
|
13
|
+
rubygem-highline \
|
|
14
|
+
rubygem-json \
|
|
15
|
+
rubygem-mime-types \
|
|
16
|
+
rubygem-net-ssh \
|
|
17
|
+
rubygem-polyglot \
|
|
18
|
+
rubygem-rest-client \
|
|
19
|
+
rubygem-treetop \
|
|
20
|
+
rubygem-uuidtools
|
|
21
|
+
|
|
22
|
+
cd /tmp
|
|
23
|
+
wget http://download.virtualbox.org/virtualbox/$VBOX_VERSION/VBoxGuestAdditions_$VBOX_VERSION.iso
|
|
24
|
+
mount -o loop,ro VBoxGuestAdditions_$VBOX_VERSION.iso /mnt
|
|
25
|
+
sh /mnt/VBoxLinuxAdditions.run
|
|
26
|
+
umount /mnt
|
|
27
|
+
rm VBoxGuestAdditions_$VBOX_VERSION.iso
|
|
28
|
+
|
|
29
|
+
gem install chef --no-rdoc --no-ri
|
|
30
|
+
|
|
31
|
+
exit
|
|
32
|
+
|
|
33
|
+
# EOF
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
Veewee::Session.declare({
|
|
2
|
+
# Minimum RAM requirement for installation is 640MB.
|
|
3
|
+
:cpu_count => '1',
|
|
4
|
+
:memory_size=> '640',
|
|
5
|
+
:disk_size => '10140',
|
|
6
|
+
:disk_format => 'VDI',
|
|
7
|
+
:hostiocache => 'off',
|
|
8
|
+
:hwvirtext => 'on',
|
|
9
|
+
:os_type_id => 'Fedora_64',
|
|
10
|
+
:iso_file => "Fedora-15-x86_64-netinst.iso",
|
|
11
|
+
:iso_src => "http://ftp.halifax.rwth-aachen.de/fedora/linux/releases/15/Fedora/x86_64/iso/Fedora-15-x86_64-netinst.iso",
|
|
12
|
+
:iso_md5 => "b2398cc55aa5b802865246f2f702899f",
|
|
13
|
+
:iso_download_timeout => 1000,
|
|
14
|
+
:boot_wait => "10",
|
|
15
|
+
:boot_cmd_sequence => [ '<Tab> linux text ks=http://%IP%:%PORT%/ks.cfg<Enter><Enter>' ],
|
|
16
|
+
:kickstart_port => "7122",
|
|
17
|
+
:kickstart_timeout => 10000,
|
|
18
|
+
:kickstart_file => "ks.cfg",
|
|
19
|
+
:ssh_login_timeout => "100",
|
|
20
|
+
:ssh_user => "vagrant",
|
|
21
|
+
:ssh_password => "vagrant",
|
|
22
|
+
:ssh_key => "",
|
|
23
|
+
:ssh_host_port => "7222",
|
|
24
|
+
:ssh_guest_port => "22",
|
|
25
|
+
:sudo_cmd => "echo '%p'|sudo -S sh '%f'",
|
|
26
|
+
:shutdown_cmd => "/sbin/halt -h -p",
|
|
27
|
+
:postinstall_files => [ "postinstall.sh"],
|
|
28
|
+
:postinstall_timeout => 10000
|
|
29
|
+
})
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
# Kickstart file automatically generated by anaconda.
|
|
2
|
+
|
|
3
|
+
install
|
|
4
|
+
cdrom
|
|
5
|
+
lang en_US.UTF-8
|
|
6
|
+
keyboard us
|
|
7
|
+
network --onboot yes --device p2p1 --bootproto dhcp --noipv6
|
|
8
|
+
timezone --utc America/Los_Angeles
|
|
9
|
+
rootpw --iscrypted $6$n/NGsk5H2aiBMXL4$r/oPkJtB5rasvQHPo9AvIJBe6sNVlQbpZxvTRMN7.qZk/Sn9u2qZ0XgNxflUvK20y7OIWdr/vv7MED6gzkBiH0
|
|
10
|
+
selinux --enforcing
|
|
11
|
+
authconfig --enableshadow --passalgo=sha512
|
|
12
|
+
firewall --service=ssh
|
|
13
|
+
# The following is the partition information you requested
|
|
14
|
+
# Note that any partitions you deleted are not expressed
|
|
15
|
+
# here so unless you clear all partitions first, this is
|
|
16
|
+
# not guaranteed to work
|
|
17
|
+
clearpart --all --drives=sda --initlabel
|
|
18
|
+
|
|
19
|
+
part /boot --fstype=ext4 --size=500
|
|
20
|
+
part pv.2 --grow --size=500
|
|
21
|
+
|
|
22
|
+
volgroup vg_vagrant --pesize=32768 pv.2
|
|
23
|
+
logvol / --fstype=ext4 --name=lv_root --vgname=vg_vagrant --size=1024 --grow
|
|
24
|
+
logvol swap --fstype=swap --name=lv_swap --vgname=vg_vagrant --size=528 --grow --maxsize=1056
|
|
25
|
+
bootloader --location=mbr --driveorder=sda --append="norhgb"
|
|
26
|
+
# Disable remote repositories, as this is a non-netinst install.
|
|
27
|
+
#repo --name="Fedora 15 - x86_64" --mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=fedora-15&arch=x86_64 --cost=1000
|
|
28
|
+
#repo --name="Fedora 15 - x86_64 - Updates" --mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=updates-released-f15&arch=x86_64 --cost=1000
|
|
29
|
+
services --enabled network
|
|
30
|
+
reboot
|
|
31
|
+
|
|
32
|
+
%packages
|
|
33
|
+
@core
|
|
34
|
+
@online-docs
|
|
35
|
+
|
|
36
|
+
# Requirements for vagrant
|
|
37
|
+
kernel-devel
|
|
38
|
+
kernel-headers
|
|
39
|
+
make
|
|
40
|
+
gcc
|
|
41
|
+
%end
|
|
42
|
+
|
|
43
|
+
%post
|
|
44
|
+
# Make ssh quicker in disconnected situations.
|
|
45
|
+
echo 'UseDNS no' >> /etc/ssh/sshd_config
|
|
46
|
+
|
|
47
|
+
# Add Vagrant user and group.
|
|
48
|
+
/usr/sbin/groupadd vagrant
|
|
49
|
+
/usr/sbin/useradd vagrant -g vagrant
|
|
50
|
+
echo "vagrant"|passwd --stdin vagrant
|
|
51
|
+
|
|
52
|
+
# Give Vagrant user permission to sudo.
|
|
53
|
+
echo 'Defaults:vagrant !requiretty' > /etc/sudoers.d/vagrant
|
|
54
|
+
echo '%vagrant ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers.d/vagrant
|
|
55
|
+
chmod 440 /etc/sudoers.d/vagrant
|
|
56
|
+
|
|
57
|
+
# Install vagrant authorized ssh key.
|
|
58
|
+
mkdir /home/vagrant/.ssh
|
|
59
|
+
curl -L 'http://github.com/mitchellh/vagrant/raw/master/keys/vagrant.pub' > /home/vagrant/.ssh/authorized_keys
|
|
60
|
+
chown vagrant:vagrant -R /home/vagrant/.ssh
|
|
61
|
+
chmod 700 /home/vagrant/.ssh
|
|
62
|
+
chmod 600 /home/vagrant/.ssh/authorized_keys
|
|
63
|
+
chcon -R unconfined_u:object_r:user_home_t:s0 /home/vagrant/.ssh
|
|
64
|
+
%end
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
#!/bin/sh
|
|
2
|
+
|
|
3
|
+
date > /etc/vagrant_box_build_time
|
|
4
|
+
|
|
5
|
+
VBOX_VERSION=$(cat /home/vagrant/.vbox_version)
|
|
6
|
+
|
|
7
|
+
yum -y install \
|
|
8
|
+
ruby \
|
|
9
|
+
ruby-devel \
|
|
10
|
+
puppet \
|
|
11
|
+
rubygems \
|
|
12
|
+
rubygem-erubis \
|
|
13
|
+
rubygem-highline \
|
|
14
|
+
rubygem-json \
|
|
15
|
+
rubygem-mime-types \
|
|
16
|
+
rubygem-net-ssh \
|
|
17
|
+
rubygem-polyglot \
|
|
18
|
+
rubygem-rest-client \
|
|
19
|
+
rubygem-treetop \
|
|
20
|
+
rubygem-uuidtools
|
|
21
|
+
|
|
22
|
+
cd /tmp
|
|
23
|
+
wget http://download.virtualbox.org/virtualbox/$VBOX_VERSION/VBoxGuestAdditions_$VBOX_VERSION.iso
|
|
24
|
+
mount -o loop,ro VBoxGuestAdditions_$VBOX_VERSION.iso /mnt
|
|
25
|
+
sh /mnt/VBoxLinuxAdditions.run
|
|
26
|
+
umount /mnt
|
|
27
|
+
rm VBoxGuestAdditions_$VBOX_VERSION.iso
|
|
28
|
+
|
|
29
|
+
gem install chef --no-rdoc --no-ri
|
|
30
|
+
|
|
31
|
+
exit
|
|
32
|
+
|
|
33
|
+
# EOF
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
Veewee::Session.declare({
|
|
2
|
+
# Minimum RAM requirement for installation is 640MB.
|
|
3
|
+
:cpu_count => '1', :memory_size=> '640',
|
|
4
|
+
:disk_size => '10140', :disk_format => 'VDI', :hostiocache => 'off', :hwvirtext => 'on',
|
|
5
|
+
:os_type_id => 'Fedora_64',
|
|
6
|
+
:iso_file => "Fedora-15-x86_64-DVD.iso",
|
|
7
|
+
:iso_src => "http://download.fedoraproject.org/pub/fedora/linux/releases/15/Fedora/x86_64/iso/Fedora-15-x86_64-DVD.iso",
|
|
8
|
+
:iso_md5 => "c122a2a4f478da4a3d2d12396e84244e",
|
|
9
|
+
:iso_download_timeout => 1000,
|
|
10
|
+
:boot_wait => "10", :boot_cmd_sequence => [ '<Tab> linux text ks=http://%IP%:%PORT%/ks.cfg<Enter><Enter>' ],
|
|
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",
|
|
14
|
+
:sudo_cmd => "echo '%p'|sudo -S sh '%f'",
|
|
15
|
+
:shutdown_cmd => "/sbin/halt -h -p",
|
|
16
|
+
:postinstall_files => [ "postinstall.sh"], :postinstall_timeout => 10000
|
|
17
|
+
})
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
# Kickstart file automatically generated by anaconda.
|
|
2
|
+
|
|
3
|
+
install
|
|
4
|
+
cdrom
|
|
5
|
+
lang en_US.UTF-8
|
|
6
|
+
keyboard us
|
|
7
|
+
network --onboot yes --device p2p1 --bootproto dhcp --noipv6
|
|
8
|
+
timezone --utc America/Los_Angeles
|
|
9
|
+
rootpw --iscrypted $6$n/NGsk5H2aiBMXL4$r/oPkJtB5rasvQHPo9AvIJBe6sNVlQbpZxvTRMN7.qZk/Sn9u2qZ0XgNxflUvK20y7OIWdr/vv7MED6gzkBiH0
|
|
10
|
+
selinux --enforcing
|
|
11
|
+
authconfig --enableshadow --passalgo=sha512
|
|
12
|
+
firewall --service=ssh
|
|
13
|
+
# The following is the partition information you requested
|
|
14
|
+
# Note that any partitions you deleted are not expressed
|
|
15
|
+
# here so unless you clear all partitions first, this is
|
|
16
|
+
# not guaranteed to work
|
|
17
|
+
clearpart --all --drives=sda --initlabel
|
|
18
|
+
|
|
19
|
+
part /boot --fstype=ext4 --size=500
|
|
20
|
+
part pv.2 --grow --size=500
|
|
21
|
+
|
|
22
|
+
volgroup vg_vagrant --pesize=32768 pv.2
|
|
23
|
+
logvol / --fstype=ext4 --name=lv_root --vgname=vg_vagrant --size=1024 --grow
|
|
24
|
+
logvol swap --fstype=swap --name=lv_swap --vgname=vg_vagrant --size=528 --grow --maxsize=1056
|
|
25
|
+
bootloader --location=mbr --driveorder=sda --append="norhgb"
|
|
26
|
+
# Disable remote repositories, as this is a non-netinst install.
|
|
27
|
+
#repo --name="Fedora 15 - x86_64" --mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=fedora-15&arch=x86_64 --cost=1000
|
|
28
|
+
#repo --name="Fedora 15 - x86_64 - Updates" --mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=updates-released-f15&arch=x86_64 --cost=1000
|
|
29
|
+
services --enabled network
|
|
30
|
+
reboot
|
|
31
|
+
|
|
32
|
+
%packages
|
|
33
|
+
@core
|
|
34
|
+
@online-docs
|
|
35
|
+
|
|
36
|
+
# Requirements for vagrant
|
|
37
|
+
kernel-devel
|
|
38
|
+
kernel-headers
|
|
39
|
+
make
|
|
40
|
+
gcc
|
|
41
|
+
%end
|
|
42
|
+
|
|
43
|
+
%post
|
|
44
|
+
# Make ssh quicker in disconnected situations.
|
|
45
|
+
echo 'UseDNS no' >> /etc/ssh/sshd_config
|
|
46
|
+
|
|
47
|
+
# Add Vagrant user and group.
|
|
48
|
+
/usr/sbin/groupadd vagrant
|
|
49
|
+
/usr/sbin/useradd vagrant -g vagrant
|
|
50
|
+
echo "vagrant"|passwd --stdin vagrant
|
|
51
|
+
|
|
52
|
+
# Give Vagrant user permission to sudo.
|
|
53
|
+
echo 'Defaults:vagrant !requiretty' > /etc/sudoers.d/vagrant
|
|
54
|
+
echo '%vagrant ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers.d/vagrant
|
|
55
|
+
chmod 440 /etc/sudoers.d/vagrant
|
|
56
|
+
|
|
57
|
+
# Install vagrant authorized ssh key.
|
|
58
|
+
mkdir /home/vagrant/.ssh
|
|
59
|
+
curl -L 'http://github.com/mitchellh/vagrant/raw/master/keys/vagrant.pub' > /home/vagrant/.ssh/authorized_keys
|
|
60
|
+
chown vagrant:vagrant -R /home/vagrant/.ssh
|
|
61
|
+
chmod 700 /home/vagrant/.ssh
|
|
62
|
+
chmod 600 /home/vagrant/.ssh/authorized_keys
|
|
63
|
+
chcon -R unconfined_u:object_r:user_home_t:s0 /home/vagrant/.ssh
|
|
64
|
+
%end
|