root/galaxy-central/contrib/galaxy.debian-init @ 2

リビジョン 2, 1.2 KB (コミッタ: hatakeyama, 14 年 前)

import galaxy-central

行番号 
1#!/bin/bash
2
3# Author: James Casbon, 2009
4
5### BEGIN INIT INFO
6# Provides:             galaxy
7# Required-Start:       $network $local_fs $mysql
8# Required-Stop:
9# Default-Start:        2 3 4 5
10# Default-Stop:         0 1 6
11# Short-Description:    Galaxy
12### END INIT INFO
13
14. /lib/lsb/init-functions
15
16USER="galaxy"
17GROUP="nogroup"
18DIR="/home/galaxy/galaxy_dist/"
19PYTHON="/usr/bin/python"
20OPTS="-ES ./scripts/paster.py serve --log-file /home/galaxy/galaxy.log universe_wsgi.ini"
21PIDFILE="/var/run/galaxy.pid"
22
23case "${1:-''}" in
24  'start')
25           log_daemon_msg "Starting Galaxy"
26           if start-stop-daemon --chuid $USER --group $GROUP --start --make-pidfile \
27                     --pidfile $PIDFILE --background --chdir $DIR --exec $PYTHON -- $OPTS; then
28             log_end_msg 0
29           else
30             log_end_msg 1
31           fi
32
33        ;;
34  'stop')
35           log_daemon_msg "Stopping Galaxy"
36           if start-stop-daemon --stop --pidfile $PIDFILE; then
37             log_end_msg 0
38           else
39             log_end_msg 1
40           fi
41        ;;
42  'restart')
43           # restart commands here
44           $0 stop
45           $0 start
46                           
47        ;;
48  *)      # no parameter specified
49        echo "Usage: $SELF start|stop|restart|reload|force-reload|status"
50        exit 1
51        ;;
52esac
53
54
55
Note: リポジトリブラウザについてのヘルプは TracBrowser を参照してください。