~ubuntu-core-dev/silo-installer/ubuntu

« back to all changes in this revision

Viewing changes to debian/silo-installer.postinst

  • Committer: Ben Collins
  • Date: 2003-02-20 17:21:14 UTC
  • Revision ID: git-v1:71bd297aedf7e00178c3a5186a6445067bc7c643
Start of sparc code. SILO install template in place.

r1973

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/bin/sh
 
2
set -e
 
3
 
 
4
if [ -f /etc/mtab ]; then
 
5
    MTAB=/etc/mtab
 
6
else
 
7
    MTAB=/proc/mounts
 
8
fi
 
9
 
 
10
# detect which is the root partition: /target
 
11
rootfs=`/target/bin/sed -ne '/^[^ ]* \/target /s/ .*//p' $MTAB`
 
12
 
 
13
. /usr/share/debconf/confmodule
 
14
 
 
15
rootfs=`mapdevfs $rootfs`
 
16
 
 
17
# Write out silo.conf
 
18
cat > /target/etc/silo.conf << EOF
 
19
root=$rootfs
 
20
timeout=100
 
21
image=/vmlinuz
 
22
        label=Linux
 
23
        read-only
 
24
EOF
 
25
 
 
26
chmod 644 /target/etc/silo.conf
 
27
 
 
28
chroot /target /sbin/silo -f