Last change
on this file since 75 was
70,
checked in by bas, 17 years ago
|
DEBIAN/postinst:
- Used wrong statement for inetd check
|
-
Property svn:executable set to
*
-
Property svn:keywords set to
Id URL
|
File size:
776 bytes
|
Rev | Line | |
---|
[40] | 1 | #!/bin/sh |
---|
[68] | 2 | # |
---|
| 3 | # SVN Info: |
---|
| 4 | # $Id: postinst 70 2006-11-14 11:25:00Z bas $ |
---|
| 5 | # $URL: trunk/DEBIAN/postinst $ |
---|
[40] | 6 | |
---|
| 7 | DAEMON=beo_pxeconfigd |
---|
| 8 | PORT=6611 |
---|
| 9 | |
---|
| 10 | PXE_TEST=`grep $DAEMON /etc/services` |
---|
| 11 | |
---|
[44] | 12 | if [ ! -z "$PXE_TEST" ]; then |
---|
[40] | 13 | echo "WARNING: $DAEMON already in /etc/services" |
---|
| 14 | else |
---|
| 15 | echo -e "$DAEMON\t$PORT/tcp\t\t\t# pxe config daemon\n" >> /etc/services |
---|
| 16 | fi |
---|
| 17 | |
---|
[45] | 18 | if [ -d /etc/xinetd.d ] && [ ! -r /etc/xinetd.d/$DAEMON ] |
---|
[68] | 19 | then |
---|
[45] | 20 | cat <<EOF >/etc/xinetd.d/$DAEMON |
---|
| 21 | service $DAEMON |
---|
[44] | 22 | { |
---|
| 23 | disable = no |
---|
| 24 | socket_type = stream |
---|
| 25 | protocol = tcp |
---|
| 26 | user = root |
---|
| 27 | group = sys |
---|
| 28 | wait = no |
---|
[45] | 29 | server = /usr/sbin/$DAEMON |
---|
[44] | 30 | } |
---|
| 31 | EOF |
---|
[40] | 32 | |
---|
[44] | 33 | /etc/init.d/xinetd reload |
---|
| 34 | |
---|
[70] | 35 | elif [ -x /etc/init.d/inetd ] |
---|
[68] | 36 | then |
---|
[44] | 37 | update-inetd --add "$DAEMON\tstream\ttcp\tnowait\troot.sys\t/usr/sbin/tcpd\t/usr/sbin/$DAEMON" |
---|
| 38 | /etc/init.d/inetd reload |
---|
| 39 | fi |
---|
Note: See
TracBrowser
for help on using the repository browser.