Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:p_conrad
nullmailer
rc.nullmailer
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File rc.nullmailer of Package nullmailer
#!/bin/sh # # init.d/nullmailer # # (C) 2011 Peter Conrad <conrad@quisquis.de> # # This program is licensed under the terms of the # GNU General Public License Version 2. A copy of these terms should be # enclosed as "COPYING" in the package containing this file. # ### BEGIN INIT INFO # Provides: nullmailer # Required-Start: $local_fs $network $remote_fs # Required-Stop: $local_fs $network $remote_fs # Default-Start: 2 3 5 # Default-Stop: 0 1 4 6 # Short-Description: Start nullmailer MTA # Description: Start nullmailer MTA ### END INIT INFO . /etc/rc.status rc_reset PATH=/bin:/usr/bin:/sbin:/usr/sbin export PATH running() { if [ ! -r "$PIDFILE" ]; then return 1 fi read pid <"$PIDFILE" if [ -z "$pid" ]; then return 1 fi if [ ! -r "/proc/$pid/cmdline" ]; then return 1 fi grep -q nullmailer "/proc/$pid/cmdline" } PIDFILE=/var/run/nullmailer.pid case "$1" in start) if running; then : else echo -n "Starting nullmailer..." cd /usr/lib/nullmailer/service/log (( env - PATH=$PATH \ /usr/lib/nullmailer/service/run & echo $! >"$PIDFILE" ) | \ ./run ) </dev/null >/dev/null 2>&1 & fi rc_status -v ;; stop) if running; then echo -n "Shutting down nullmailer..." kill "`cat "$PIDFILE"`" fi rc_status -v ;; restart) "$0" stop && "$0" start ;; condrestart|try-restart) if running; then "$0" restart fi ;; reload|force-reload) # Control files are re-read everytime the queue is run ;; status) if running; then exit 0 fi if [ -r "$PIDFILE" ]; then exit 1 fi exit 2 ;; *) echo "Usage: $0 {start|stop|restart|condrestart|try-restart|reload|force-reload|status}" exit 1 esac exit 0
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor