File: syslog-cleanup.sh

package info (click to toggle)
dracut 110-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 4,356 kB
  • sloc: sh: 24,895; ansic: 5,236; makefile: 346; perl: 186; python: 48; javascript: 19
file content (14 lines) | stat: -rwxr-xr-x 416 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/bin/sh

# Just cleans up a previously started syslogd

command -v getarg > /dev/null || . /lib/dracut-lib.sh

if [ -f /tmp/syslog.server ]; then
    read -r syslogtype < /tmp/syslog.type
    if command -v "${syslogtype}-stop" > /dev/null; then
        "${syslogtype}"-stop
    else
        warn "syslog-cleanup: Could not find script to stop syslog of type \"$syslogtype\". Syslog will not be stopped."
    fi
fi