archives/mastodon: new aport
This commit is contained in:
parent
9f6c072b60
commit
e7773e8def
10 changed files with 445 additions and 0 deletions
41
archives/mastodon/mastodon.initd
Normal file
41
archives/mastodon/mastodon.initd
Normal file
|
@ -0,0 +1,41 @@
|
|||
#!/sbin/openrc-run
|
||||
|
||||
name="Mastodon"
|
||||
description="Meta script for starting/stopping all the Mastodon components"
|
||||
|
||||
subservices="mastodon.sidekiq mastodon.streaming mastodon.web"
|
||||
|
||||
depend() {
|
||||
need redis postgresql
|
||||
use net
|
||||
}
|
||||
|
||||
start() {
|
||||
local ret=0
|
||||
|
||||
ebegin "Starting all Mastodon components"
|
||||
local svc; for svc in $subservices; do
|
||||
service $svc start || ret=1
|
||||
done
|
||||
eend $ret
|
||||
}
|
||||
|
||||
stop() {
|
||||
local ret=0
|
||||
|
||||
ebegin "Stopping all Mastodon components"
|
||||
local svc; for svc in $subservices; do
|
||||
service $svc stop || ret=1
|
||||
done
|
||||
eend $ret
|
||||
}
|
||||
|
||||
status() {
|
||||
local ret=0
|
||||
|
||||
local svc; for svc in $subservices; do
|
||||
echo "$svc:"
|
||||
service $svc status || ret=1
|
||||
done
|
||||
eend $ret
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue