summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorVasily Mikhaylichenko <vaskas@lxmx.com.au>2016-07-02 00:24:41 +1000
committer无闻 <u@gogs.io>2016-07-01 22:24:41 +0800
commitf0df46c88a9854cbb46221ac6d076e6062a9efc1 (patch)
treefb3db28ec4350980b2f4fbf275a3d83479916467 /scripts
parente84ac64964dc3011e6bc12dfbe6abfad3c0f0f3d (diff)
downloadgitea-f0df46c88a9854cbb46221ac6d076e6062a9efc1.tar.gz
gitea-f0df46c88a9854cbb46221ac6d076e6062a9efc1.zip
Add an OpenBSD daemon control script (#3060)
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/init/openbsd/gogs19
1 files changed, 19 insertions, 0 deletions
diff --git a/scripts/init/openbsd/gogs b/scripts/init/openbsd/gogs
new file mode 100755
index 0000000000..95fcf16965
--- /dev/null
+++ b/scripts/init/openbsd/gogs
@@ -0,0 +1,19 @@
+#!/bin/sh
+#
+# $OpenBSD$
+
+daemon="/home/git/gogs/gogs"
+daemon_user="git"
+daemon_flags="web"
+
+gogs_directory="/home/git/gogs"
+
+rc_bg=YES
+
+. /etc/rc.d/rc.subr
+
+rc_start() {
+ ${rcexec} "cd ${gogs_directory}; ${daemon} ${daemon_flags} ${_bg}"
+}
+
+rc_cmd $1