Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
saemproject
saemref-formula
Commits
f9f545ca
Commit
f9f545ca
authored
Feb 09, 2017
by
Philippe Pepiot
Committed by
Denis Laxalde
Feb 09, 2017
Browse files
supervisor: remove main config and init script
They are unused now (was for centos 6)
parent
e9972f9c
Changes
2
Hide whitespace changes
Inline
Side-by-side
saemref/files/supervisord.conf
deleted
100644 → 0
View file @
e9972f9c
{%
from
"saemref/map.jinja"
import
supervisor_confdir
with
context
-%}
[
unix_http_server
]
file
=/
tmp
/
supervisor
.
sock
; (
the
path
to
the
socket
file
)
[
supervisord
]
logfile
=/
tmp
/
supervisord
.
log
; (
main
log
file
;
default
$
CWD
/
supervisord
.
log
)
logfile_maxbytes
=
50
MB
; (
max
main
logfile
bytes
b4
rotation
;
default
50
MB
)
logfile_backups
=
10
; (
num
of
main
logfile
rotation
backups
;
default
10
)
loglevel
=
info
; (
log
level
;
default
info
;
others
:
debug
,
warn
,
trace
)
pidfile
=/
tmp
/
supervisord
.
pid
; (
supervisord
pidfile
;
default
supervisord
.
pid
)
nodaemon
=
false
; (
start
in
foreground
if
true
;
default
false
)
minfds
=
1024
; (
min
.
avail
startup
file
descriptors
;
default
1024
)
minprocs
=
200
; (
min
.
avail
process
descriptors
;
default
200
)
[
rpcinterface
:
supervisor
]
supervisor
.
rpcinterface_factory
=
supervisor
.
rpcinterface
:
make_main_rpcinterface
[
supervisorctl
]
serverurl
=
unix
:///
tmp
/
supervisor
.
sock
;
use
a
unix
://
URL
for
a
unix
socket
[
include
]
files
= {{
supervisor_confdir
}}/*.
conf
saemref/files/supervisord.init
deleted
100644 → 0
View file @
e9972f9c
{% from "saemref/map.jinja" import saemref, supervisor_confdir with context %}
{% set user = saemref.instance.user %}
{% set bindir = ['/home', user, '.local', 'bin']|join('/') %}
{% set confdir = ['/home', user, 'etc']|join('/') %}
#!/bin/bash
#
# supervisord Startup script for the Supervisor process control system
#
# Author: Mike McGrath <mmcgrath@redhat.com> (based off yumupdatesd)
# Jason Koppe <jkoppe@indeed.com> adjusted to read sysconfig,
# use supervisord tools to start/stop, conditionally wait
# for child processes to shutdown, and startup later
# Erwan Queffelec <erwan.queffelec@gmail.com>
# make script LSB-compliant
#
# chkconfig: 345 83 04
# description: Supervisor is a client/server system that allows \
# its users to monitor and control a number of processes on \
# UNIX-like operating systems.
# processname: supervisord
# config: {{ confdir }}/supervisord.conf
# config: /etc/sysconfig/supervisord
# pidfile: /tmp/supervisord.pid
#
### BEGIN INIT INFO
# Provides: supervisord
# Required-Start: $all
# Required-Stop: $all
# Short-Description: start and stop Supervisor process control system
# Description: Supervisor is a client/server system that allows
# its users to monitor and control a number of processes on
# UNIX-like operating systems.
### END INIT INFO
# Source function library
. /etc/rc.d/init.d/functions
# Source system settings
if [ -f /etc/sysconfig/supervisord ]; then
. /etc/sysconfig/supervisord
fi
# Path to the supervisorctl script, server binary,
# and short-form for messages.
prog=supervisord
pidfile=${PIDFILE-/tmp/supervisord.pid}
lockfile=${LOCKFILE-/var/lock/subsys/supervisord}
STOP_TIMEOUT=${STOP_TIMEOUT-60}
RETVAL=0
supervisorctl() {
su -l {{ user }} -c "{{ bindir }}/supervisorctl -c {{ confdir }}/supervisord.conf $*"
}
start() {
echo -n $"Starting $prog: "
su -l {{ user }} -c "{{ bindir }}/supervisord -c {{ confdir }}/supervisord.conf"
RETVAL=$?
echo
if [ $RETVAL -eq 0 ]; then
touch ${lockfile}
supervisorctl status
fi
return $RETVAL
}
stop() {
echo -n $"Stopping $prog: "
killproc -p ${pidfile} -d ${STOP_TIMEOUT} $prog
RETVAL=$?
echo
[ $RETVAL -eq 0 ] && rm -rf ${lockfile} ${pidfile}
}
reload() {
echo -n $"Reloading $prog: "
LSB=1 killproc -p $pidfile $prog -HUP
RETVAL=$?
echo
if [ $RETVAL -eq 7 ]; then
failure $"$prog reload"
else
supervisorctl status
fi
}
restart() {
stop
start
}
case "$1" in
start)
start
;;
stop)
stop
;;
status)
status -p ${pidfile} $prog
RETVAL=$?
[ $RETVAL -eq 0 ] && supervisorctl status
;;
restart)
restart
;;
condrestart|try-restart)
if status -p ${pidfile} $prog >&/dev/null; then
stop
start
fi
;;
force-reload|reload)
reload
;;
*)
echo $"Usage: $prog {start|stop|restart|condrestart|try-restart|force-reload|reload}"
RETVAL=2
esac
exit $RETVAL
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment