Skip to content

Commit

Permalink
Merge pull request #621 from ngiger/funtoo-latest
Browse files Browse the repository at this point in the history
Brining funtoo-latest-x86_64t into a workable state
  • Loading branch information
jedi4ever committed Mar 29, 2013
2 parents 01d4afa + 567440e commit 6f8ec48
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 6 deletions.
14 changes: 8 additions & 6 deletions templates/funtoo-latest-x86_64/definition.rb
Expand Up @@ -4,12 +4,12 @@
:hostiocache => 'off',
:cpu_count => '1',
:memory_size=> '384',
:disk_size => '10140',
:disk_size => '40560', # 40 GB
:disk_format => 'VDI',
:os_type_id => 'Gentoo_64', # for 32bit, change to 'Gentoo'
:iso_file => "systemrescuecd-x86-3.0.0.iso",
:iso_src => "http://freefr.dl.sourceforge.net/project/systemrescuecd/sysresccd-x86/3.0.0/systemrescuecd-x86-3.0.0.iso",
:iso_md5 => "6bb6241af752b1d6dab6ae9e6e3e770e",
:iso_file => "install-amd64-minimal-20130110.iso",
:iso_src => "http://mirror.switch.ch/ftp/mirror/gentoo/releases/amd64/autobuilds/20130110/install-amd64-minimal-20130110.iso",
:iso_md5 => "67cfb094d159d7b359ea9797d636b6c7",
:iso_download_timeout => "1000",
:boot_wait => "4",
:boot_cmd_sequence => [
Expand All @@ -20,9 +20,11 @@
'<Wait>'*12,
'<Enter><Wait>', # just in case we are out of sync
'net-setup eth0<Enter><Wait><Enter>2<Enter>1<Enter><Wait><Wait>',
'ifconfig -a <Enter><Wait><Wait>',
'passwd<Enter><Wait><Wait>',
password + '<Enter><Wait>',
password + '<Enter><Wait><Wait>'
password + '<Enter><Wait><Wait>',
'/etc/init.d/sshd start<Enter><Wait><Wait>'
],
:ssh_login_timeout => "10000",
:ssh_user => "root",
Expand All @@ -31,7 +33,7 @@
:ssh_host_port => "7222",
:ssh_guest_port => "22",
:sudo_cmd => "cat '%f'|su -",
:shutdown_cmd => "shutdown -p now",
:shutdown_cmd => "init 0",
:postinstall_files => ["postinstall.sh"],
:postinstall_timeout => "15000"
})
16 changes: 16 additions & 0 deletions templates/funtoo-latest-x86_64/postinstall.sh
Expand Up @@ -49,6 +49,10 @@ swapon /dev/sda3
mkfs.ext2 /dev/sda1
mkfs.ext4 /dev/sda4

# verify to be sure that partitions are okay
sgdisk -v /dev/sda
sgdisk -p /dev/sda

# this is our chroot directory for the installation
chroot=/mnt/gentoo

Expand Down Expand Up @@ -358,8 +362,20 @@ source /etc/profile && \
env-update && \
grub-install --no-floppy /dev/sda && \
boot-update
# Patching the boot configuration as we have no initramfs
cd /boot/grub
mv grub.cfg grub.bkp
awk '{sub(/real_root/,"root")};1' grub.bkp > grub.cfg
cat grub.cfg
DATAEOF

### patch to make lib/vagrant/guest/gentoo.rb happy
chroot "$chroot" /bin/bash <<DATAEOF
cd /etc/init.d
ln -s net.lo netif.lo
DATAEOF


### CLEANUP TO SHRINK THE BOX ###

# a fresh install probably shouldn't nag about news
Expand Down

0 comments on commit 6f8ec48

Please sign in to comment.