Created
December 13, 2016 04:26
-
-
Save wilxsv/6b186022c082f75cbb7447e52a1b38d2 to your computer and use it in GitHub Desktop.
Script para iniciar jasper server como demonio de debian - http://community.jaspersoft.com/questions/541044/auto-start-boot
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Tomado del sitio http://community.jaspersoft.com/questions/541044/auto-start-boot | |
### BEGIN INIT INFO | |
# Provides: jasperserver | |
# Required-Start: $local_fs $remote_fs $network $time $syslog | |
# Required-Stop: $local_fs $remote_fs $network $time $syslog | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 | |
# Short-Description: Start JasperServer at boot time | |
# Description: Enable service provided by JasperServer. | |
### END INIT INFO | |
JASPER_HOME="/opt/jasperreports-server-cp-6.3.0" | |
case "$1" in | |
start) | |
if [ -f $JASPER_HOME/ctlscript.sh ]; then | |
echo "Starting JasperServer" | |
$JASPER_HOME/ctlscript.sh start | |
fi | |
;; | |
stop) | |
if [ -f $JASPER_HOME/ctlscript.sh ]; then | |
echo "Stopping JasperServer" | |
$JASPER_HOME/ctlscript.sh stop | |
fi | |
;; | |
restart) | |
if [ -f $JASPER_HOME/ctlscript.sh ]; then | |
echo "Restarting JasperServer" | |
$JASPER_HOME/ctlscript.sh restart | |
fi | |
;; | |
status) | |
if [ -f $JASPER_HOME/ctlscript.sh ]; then | |
$JASPER_HOME/ctlscript.sh status | |
fi | |
;; | |
*) | |
echo $"Usage: $0 {start|stop|restart|status}" | |
exit 1 | |
;; | |
esac |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment