Merge branch 'main' of dev.hostsharing.net:hostsharing/hs.scripts
This commit is contained in:
commit
fc352f2ff3
@ -3,3 +3,6 @@ user=
|
|||||||
db=${pac}_${user}
|
db=${pac}_${user}
|
||||||
dbuser=$db
|
dbuser=$db
|
||||||
dump=$HOME/var/db/nextcloud.dump
|
dump=$HOME/var/db/nextcloud.dump
|
||||||
|
# optional version control, if default or configured one is too old
|
||||||
|
# do not comment this
|
||||||
|
php=php
|
@ -4,7 +4,7 @@ set -e
|
|||||||
# +x does not apply
|
# +x does not apply
|
||||||
# use correct order – eg: sudo -u www-data php=php8.2 ...
|
# use correct order – eg: sudo -u www-data php=php8.2 ...
|
||||||
if [ -z ${php} ]; then
|
if [ -z ${php} ]; then
|
||||||
php="php8.1"
|
php="php8.2"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
[ -f cron.log ] && rm -v cron.log && echo "logfiles should not be here and upset the updater. consider the data directory."
|
[ -f cron.log ] && rm -v cron.log && echo "logfiles should not be here and upset the updater. consider the data directory."
|
||||||
|
17
updates/sliding-sync.sh
Normal file
17
updates/sliding-sync.sh
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
set -e
|
||||||
|
export XDG_RUNTIME_DIR=/run/user/$UID
|
||||||
|
|
||||||
|
release=`curl -L https://api.github.com/repos/matrix-org/sliding-sync/releases/latest -s | jq -r '.tag_name'`
|
||||||
|
|
||||||
|
echo ">>> stopping to avoid binary being busy"
|
||||||
|
echo
|
||||||
|
systemctl stop --user syncv3
|
||||||
|
|
||||||
|
wget --show-progress -q -O $HOME/bin/syncv3 https://github.com/matrix-org/sliding-sync/releases/download/$release/syncv3_linux_amd64
|
||||||
|
|
||||||
|
echo
|
||||||
|
echo ">>> starting...."
|
||||||
|
systemctl start --user syncv3
|
||||||
|
sleep 2
|
||||||
|
systemctl status --user syncv3
|
27
updates/synapse.sh
Normal file
27
updates/synapse.sh
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
set -e
|
||||||
|
export XDG_RUNTIME_DIR=/run/user/$UID
|
||||||
|
|
||||||
|
activate="$HOME/synapse/env/bin/activate"
|
||||||
|
domain=`ls $HOME/doms/`
|
||||||
|
|
||||||
|
if [ ! -f $activate ];
|
||||||
|
then
|
||||||
|
echo ">>> FATAL: Synapse env not detected. Stopping. Please adjust the script."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
source $activate
|
||||||
|
|
||||||
|
pip install --upgrade 'matrix-synapse[postgres]' pip
|
||||||
|
|
||||||
|
systemctl --user restart synapse
|
||||||
|
|
||||||
|
sleep 2
|
||||||
|
echo
|
||||||
|
echo ">>> Synapse has been restarted and"
|
||||||
|
echo ">>> is now reporting this version:"
|
||||||
|
curl -s "https://$domain/_synapse/admin/v1/server_version"|jq
|
||||||
|
echo
|
||||||
|
|
||||||
|
systemctl --user status synapse
|
Loading…
Reference in New Issue
Block a user