~uphackers/uphack/event.d

« back to all changes in this revision

Viewing changes to rc4

  • Committer: root
  • Date: 2008-03-19 14:51:08 UTC
  • Revision ID: root@blackbook-20080319145108-9lzaud8h1m63ny57
Initial import into bzr.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# rc4 - runlevel 4 compatibility
 
2
#
 
3
# This task runs the old sysv-rc runlevel 4 (user defined) scripts.  It
 
4
# is usually started by the telinit compatibility wrapper.
 
5
 
 
6
start on runlevel 4
 
7
 
 
8
stop on runlevel [!4]
 
9
 
 
10
console output
 
11
script
 
12
        set $(runlevel --set 4 || true)
 
13
        if [ "$1" != "unknown" ]; then
 
14
            PREVLEVEL=$1
 
15
            RUNLEVEL=$2
 
16
            export PREVLEVEL RUNLEVEL
 
17
        fi
 
18
 
 
19
        exec /etc/init.d/rc 4
 
20
end script