updated on Sun Jan 15 16:02:00 UTC 2012
[aur-mirror.git] / arch32 / daemon
blobc8c626b711098cf4cbebaee534a4670e3ea99934
1 #!/bin/bash
3 . /etc/rc.conf
4 . /etc/rc.d/functions
6 case $1 in
7 start)
8 stat_busy "Starting Arch32 Chroot"
9 mount --bind /proc /opt/arch32/proc
10 mount --bind /proc/bus/usb /opt/arch32/proc/bus/usb
11 mount --bind /dev /opt/arch32/dev
12 mount --bind /dev/pts /opt/arch32/dev/pts
13 mount --bind /dev/shm /opt/arch32/dev/shm
14 mount --bind /sys /opt/arch32/sys
15 mount --bind /tmp /opt/arch32/tmp
16 mount --bind /home /opt/arch32/home
17 add_daemon arch32
18 stat_done
20 stop)
21 stat_busy "Stopping Arch32 Chroot"
22 umount /opt/arch32/proc/bus/usb
23 umount /opt/arch32/proc
24 umount /opt/arch32/dev/pts
25 umount /opt/arch32/dev/shm
26 umount /opt/arch32/dev
27 umount /opt/arch32/sys
28 umount /opt/arch32/tmp
29 umount /opt/arch32/home
30 rm_daemon arch32
31 stat_done
33 restart)
34 $0 stop
35 sleep 1
36 $0 start
39 echo "usage: $0 {start|stop|restart}"
40 esac
41 exit 0