bin/server/zulip: add custom commands
This commit is contained in:
parent
de3386567a
commit
49818385ec
|
@ -5,7 +5,7 @@ colors:
|
|||
title: blue
|
||||
default_hour: 0
|
||||
default_minute: 0
|
||||
editor: /home/janekf/.local/bin/scripts/emacstty +99999
|
||||
editor: {{ env.HOME }}/.local/bin/scripts/emacstty +99999
|
||||
encrypt: false
|
||||
highlight: true
|
||||
indent_character: '|'
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
$XDG_CONFIG_HOME/jrnl
|
||||
$XDG_CONFIG_HOME/yadm
|
||||
$XDG_CONFIG_HOME/doom
|
||||
$XDG_CONFIG_HOME/git
|
||||
|
|
|
@ -1,10 +1,18 @@
|
|||
#!/bin/sh
|
||||
#!/bin/sh -e
|
||||
# Execute commands on a zulip server
|
||||
zulipdepl="/home/zulip/deployments/current"
|
||||
sudo su zulip -c "$(
|
||||
scr="$zulipdepl/scripts/$1"
|
||||
if test -f "$scr"
|
||||
then shift && echo "$scr $@"
|
||||
else echo "$zulipdepl/manage.py $@"
|
||||
fi
|
||||
)"
|
||||
case $1 in
|
||||
(upgrade)
|
||||
cd /tmp
|
||||
curl -fLO https://download.zulip.com/server/zulip-server-latest.tar.gz
|
||||
sudo "$zulipdepl/scripts/upgrade-zulip" zulip-server-latest.tar.gz;;
|
||||
(status) sudo supervisorctl status;;
|
||||
(*)
|
||||
sudo su zulip -c "$(
|
||||
scr="$zulipdepl/scripts/$1"
|
||||
if test -f "$scr"
|
||||
then shift && echo "$scr $@"
|
||||
else echo "$zulipdepl/manage.py $@"
|
||||
fi
|
||||
)";;
|
||||
esac
|
||||
|
|
Loading…
Reference in New Issue