X-Git-Url: http://git.annexia.org/?a=blobdiff_plain;f=livecd-post.sh.in;h=f85dbd0499926d3d18f60eabda6515cff54257fa;hb=3bbcbfe8c8a210aab420a97e1b0d2c9d75b0fd39;hp=c5ade08a0b763427b86e833ce39c7d3886cecc4b;hpb=fe0ff26b9757ac927f13bf97692974be41e07e23;p=virt-p2v.git diff --git a/livecd-post.sh.in b/livecd-post.sh.in index c5ade08..f85dbd0 100644 --- a/livecd-post.sh.in +++ b/livecd-post.sh.in @@ -22,33 +22,24 @@ # # $Id$ -# Create a 'p2v' init script which runs last thing during the -# boot. +# This is the virt-p2v script. -cat > /etc/init.d/p2v << '__EOF4321__' -@P2V.INIT@ -__EOF4321__ - -# Make the 'p2v' script run when the live CD boots. -chmod 0755 /etc/init.d/p2v -/sbin/restorecon /etc/init.d/p2v -/sbin/chkconfig --add p2v - -cat > /usr/bin/virt-p2v.sh << '__EOF1234__' -@VIRT-P2V.SH@ +cat > /usr/bin/virt-p2v.ml << '__EOF1234__' +@VIRT-P2V.ML@ __EOF1234__ -chmod 0755 /usr/bin/virt-p2v.sh -/sbin/restorecon /usr/bin/virt-p2v.sh +chmod 0755 /usr/bin/virt-p2v.ml +/sbin/restorecon /usr/bin/virt-p2v.ml # Install custom inittab. cat > /etc/inittab << '__EOF4123__' @INITTAB@ __EOF4123__ -# Install custom lvm.conf.new (the shell script will rename to -# lvm.conf when the time comes). -cat > /etc/lvm/lvm.conf.new << '__EOF4312__' +# Install custom lvm.conf. The script selects this by adjusting +# $LVM_SYSTEM_DIR environment variable at the right time. +cp -a /etc/lvm /etc/lvm.new +cat > /etc/lvm.new/lvm.conf << '__EOF4312__' @LVM.CONF@ __EOF4312__ @@ -70,4 +61,6 @@ echo "RUN_FIRSTBOOT=NO" > /etc/sysconfig/firstboot touch /media/.hal-mtab # Make some mountpoints. -mkdir /mnt/root \ No newline at end of file +mkdir /mnt/root + +%end