3 # openct OpenCT card service
5 # chkconfig: 2345 37 65
7 # description: OpenCT is a library for accessing smart card terminals.
9 # Source function library
10 . /etc/rc.d/init.d/functions
13 if [ ! -f /var/lock/subsys/openct ]; then
14 show "Initializing OpenCT status"
18 if [ $RETVAL -eq 0 ]; then
20 touch /var/lock/subsys/openct
25 msg_already_running openct
30 if [ -f /var/lock/subsys/openct ]; then
31 show "Shutting down OpenCT"
33 openct-control shutdown >/dev/null
35 rm -f /var/lock/subsys/openct /var/run/openct/* >/dev/null 2>&1
37 msg_not_running openct
42 if [ -f /var/lock/subsys/openct ]; then
46 msg_not_running openct
52 # See how we were called.
75 msg_usage "$0 {start|stop|restart|try-restart|force-reload|status}"