Einige (hoffentlich die letzten) Rootfiles hinzugefuegt...
[people/teissler/ipfire-2.x.git] / src / install+setup / install / mountsource.sh
CommitLineData
72d80898
MT
1#!/bin/sh
2
3#
4# to be banished by kudzu!
5#
6
7echo "Scanning source media"
8
9# scan CDROM devices
10
11for DEVICE in $(kudzu -qps -t 30 -c CDROM | grep device: | cut -d ' ' -f 2 | sort | uniq); do
12 mount /dev/${DEVICE} /cdrom 2> /dev/null
13 if [ -e /cdrom/boot ]; then
14 echo -n ${DEVICE} > /source_device
15 exit 0
16 fi
17 umount /cdrom 2> /dev/null
18done
19
20# scan HD device (usb sticks, etc.)
21for DEVICE in $(kudzu -qps -t 30 -c HD | grep device: | cut -d ' ' -f 2 | sort | uniq); do
22 mount /dev/${DEVICE}1 /cdrom 2> /dev/null
23 if [ -e /cdrom/boot ]; then
24 echo -n ${DEVICE}1 > /source_device
25 exit 1
26 fi
27 umount /cdrom 2> /dev/null
28done
29
30exit 10