]> git.mxchange.org Git - payara-vagrant.git/commitdiff
added service script for the Pre-release version
authorMike Croft <backtotheoldhouse@gmail.com>
Sun, 16 Aug 2015 17:59:25 +0000 (18:59 +0100)
committerMike Croft <backtotheoldhouse@gmail.com>
Sun, 16 Aug 2015 17:59:25 +0000 (18:59 +0100)
payara_service-PRE-RELEASE [new file with mode: 0644]

diff --git a/payara_service-PRE-RELEASE b/payara_service-PRE-RELEASE
new file mode 100644 (file)
index 0000000..15d884a
--- /dev/null
@@ -0,0 +1,34 @@
+#!/bin/sh
+#
+# Basic Payara service
+# 
+
+PAYARA_HOME=/opt/payara/payara-4.1.153/payara41
+export PAYARA_HOME
+
+
+
+start() {
+       echo -n "Starting Payara: "
+       $PAYARA_HOME/bin/asadmin start-domain $1
+}
+
+stop() {
+       echo -n "Stopping Payara: "
+       $PAYARA_HOME/bin/asadmin stop-domain $1
+}
+
+
+case "$1" in
+start)
+    start ${2:-payaradomain}
+    ;;
+stop)
+    stop ${2:-payaradomain}
+    ;;
+restart)
+    $PAYARA_HOME/bin/asadmin restart-domain >/dev/null
+    ;;
+\*)
+    echo "usage: $0 (start|stop|restart|help)"
+esac