Annotation of /mcore-src/trunk/mcore-tools/dracut/run-mcored.sh.in
Parent Directory | Revision Log
Revision 2094 -
(hide annotations)
(download)
(as text)
Fri Sep 27 07:47:47 2013 UTC (10 years, 11 months ago) by niro
Original Path: mcore-src/trunk/mcore-tools/dracut/run-mcored.sh
File MIME type: application/x-sh
File size: 887 byte(s)
Fri Sep 27 07:47:47 2013 UTC (10 years, 11 months ago) by niro
Original Path: mcore-src/trunk/mcore-tools/dracut/run-mcored.sh
File MIME type: application/x-sh
File size: 887 byte(s)
-start mcored only if an active iface was found and use net-lib to find this iface
1 | niro | 2042 | #!/bin/sh |
2 | |||
3 | if [ -x /usr/sbin/sslsvd -a -x /usr/sbin/mcored -a -x /usr/sbin/udhcpc -a -f /etc/conf.d/mcored ] | ||
4 | then | ||
5 | niro | 2071 | if getargbool 1 rd.mcored |
6 | then | ||
7 | niro | 2094 | . /lib/dracut-lib.sh |
8 | . /lib/net-lib.sh | ||
9 | |||
10 | _myiface="${find_iface_with_link}" | ||
11 | if [[ -n ${_myiface} ]] | ||
12 | then | ||
13 | # setup networking | ||
14 | info "Setup networking" | ||
15 | /usr/bin/ip link set "${_myiface}" up | ||
16 | /usr/sbin/udhcpc -i "${_myiface}" | ||
17 | # print ip config | ||
18 | info "Current ip settings:" | ||
19 | info "$(ip addr)" | ||
20 | # remont /sysroot writeable | ||
21 | info "Remount /sysroot writeable" | ||
22 | mount -oremount,rw /sysroot | ||
23 | # start mcored | ||
24 | info "Starting mcore daemon" | ||
25 | export MROOT=/sysroot | ||
26 | . /etc/conf.d/mcored | ||
27 | /usr/sbin/sslsvd -U ${SSL_USER} -/ ${CHROOT_DIR} \ | ||
28 | -Z ${SSL_CERT} -K ${SSL_KEY} \ | ||
29 | 0 6666 /usr/sbin/mcored | ||
30 | # remount sysroot read-only | ||
31 | info "Remount /sysroot read-only" | ||
32 | mount -oremount,ro /sysroot | ||
33 | fi | ||
34 | niro | 2071 | fi |
35 | niro | 2042 | fi |