summaryrefslogtreecommitdiffstats
path: root/contrib/febootstrap/install.sh
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/febootstrap/install.sh')
-rwxr-xr-xcontrib/febootstrap/install.sh39
1 files changed, 39 insertions, 0 deletions
diff --git a/contrib/febootstrap/install.sh b/contrib/febootstrap/install.sh
new file mode 100755
index 00000000..9d86d600
--- /dev/null
+++ b/contrib/febootstrap/install.sh
@@ -0,0 +1,39 @@
+#!/bin/sh -
+
+#vm=/tmp/vm.img
+vm=/mnt/share/tmp/vm.img
+
+modules="--group-install Core -i kernel -i grub"
+
+# Choose one:
+#febootstrap $modules fedora-10 local
+febootstrap $modules fedora-11 local
+#febootstrap $modules centos-5 local http://mirror.centos.org/centos-5/5.3/os/i386/
+
+tar zcf local.tar.gz local
+#rm -rf local
+
+guestfish <<EOF
+#alloc $vm 8GB
+add $vm
+run
+sfdisk /dev/sda 0 0 0 ',100 ,'
+echo Size of /dev/sda1:
+blockdev-getsize64 /dev/sda1
+echo Size of /dev/sda2:
+blockdev-getsize64 /dev/sda2
+lvm-remove-all
+pvcreate /dev/sda2
+vgcreate VG /dev/sda2
+lvcreate Root VG 6000
+lvcreate Swap VG 500
+mkfs ext3 /dev/sda1
+mkfs ext3 /dev/VG/Root
+mount /dev/VG/Root /
+mkdir /boot
+mount /dev/sda1 /boot
+tgz-in local.tar.gz /
+grub-install / /dev/sda
+EOF
+
+#rm local.tar.gz