~racb/ubuntu/precise/swift/900888

« back to all changes in this revision

Viewing changes to debian/swift-container.init

  • Committer: Package Import Robot
  • Author(s): Chuck Short
  • Date: 2011-08-26 14:11:09 UTC
  • mfrom: (1.1.9 upstream)
  • Revision ID: package-import@ubuntu.com-20110826141109-l22gm3x1xitbsccf
Tags: 1.4.3~20110823.347-0ubuntu1
New upstream release.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
#! /bin/sh
2
2
### BEGIN INIT INFO
3
 
# Provides:          swift-container-server
 
3
# Provides:          swift-container
4
4
# Required-Start:    $remote_fs
5
5
# Required-Stop:     $remote_fs
6
6
# Default-Start:     2 3 4 5
9
9
# Description:       Container server for swift.
10
10
### END INIT INFO
11
11
 
12
 
/usr/bin/swift-init container-server $1
13
 
 
 
12
SERVICE_NAME="container-server"
 
13
PRINT_NAME="container server"
 
14
 
 
15
. /lib/lsb/init-functions
 
16
 
 
17
if ! [ -x /usr/bin/swift-init ] ; then
 
18
        exit 0
 
19
fi
 
20
  
 
21
case "$1" in
 
22
start)
 
23
        log_daemon_msg "Starting Swift ${PRINT_NAME}" "swift-init ${SERVICE_NAME}"
 
24
        /usr/bin/swift-init ${SERVICE_NAME} start
 
25
        log_end_msg $?
 
26
;;
 
27
stop)
 
28
        log_daemon_msg "Stopping Swift ${PRINT_NAME}" "swift-init ${SERVICE_NAME}"
 
29
        /usr/bin/swift-init ${SERVICE_NAME} stop
 
30
        log_end_msg $?
 
31
;;
 
32
restart|force-reload|reload)
 
33
        log_daemon_msg "Restarting Swift ${PRINT_NAME}" "swift-init ${SERVICE_NAME}"
 
34
        /usr/bin/swift-init ${SERVICE_NAME} reload
 
35
;;
 
36
status)
 
37
        exec /usr/bin/swift-init ${SERVICE_NAME} status
 
38
;;
 
39
*)
 
40
        echo "Usage: $0 {start|stop|restart|reload}"
 
41
        exit 1
 
42
;;
 
43
esac
 
44
 
 
45
exit 0