aboutsummaryrefslogtreecommitdiff
path: root/galileo/file
diff options
context:
space:
mode:
authorSlack Coder <slackcoder@server.ky>2025-07-21 07:02:58 -0500
committerSlack Coder <slackcoder@server.ky>2025-07-21 07:33:11 -0500
commit3f799ac48e925555c5a771558633675cf3819cdf (patch)
tree3f038e4ec2dfa6b17e3801bffa249a9b09c6f4c5 /galileo/file
parent739ec900efe908526b937a7a85bb97db533e5535 (diff)
downloadslackbuilds-master.tar.xz
galileo: add rc scriptHEADmaster
Diffstat (limited to 'galileo/file')
-rw-r--r--galileo/file/rc.galileo.new52
1 files changed, 52 insertions, 0 deletions
diff --git a/galileo/file/rc.galileo.new b/galileo/file/rc.galileo.new
new file mode 100644
index 0000000..bf51872
--- /dev/null
+++ b/galileo/file/rc.galileo.new
@@ -0,0 +1,52 @@
+#!/bin/sh
+#
+# Startup/shutdown script for the galileo gemini proxy.
+#
+
+galileo_start() {
+ if >/dev/null pidof galileo; then
+ echo "galileo is already running"
+ return
+ fi
+
+ echo -n "Starting the galileo gemini proxy: "
+ if galileo; then
+ echo "success"
+ else
+ echo "failed"
+ fi
+}
+
+galileo_status() {
+ if >/dev/null pidof galileo; then
+ echo "galileo is running"
+ else
+ echo "galileo is not running"
+ fi
+}
+
+galileo_stop() {
+ if ! >/dev/null pidof galileo; then
+ echo "galileo is not running"
+ return
+ fi
+
+ echo "Stopping the galileo gemini proxy"
+ pkill --exact -TERM galileo
+}
+
+case "$1" in
+start)
+ galileo_start
+ ;;
+status)
+ galileo_status
+ ;;
+stop)
+ galileo_stop
+ ;;
+*)
+ echo "Usage: $0 {reload|start|status|stop}"
+ exit 1
+esac
+