matrix
This commit is contained in:
parent
cbcbf28eec
commit
28e9f2c3df
10
basics.yml
10
basics.yml
@ -740,6 +740,7 @@
|
|||||||
done
|
done
|
||||||
|
|
||||||
message="$(cat)"
|
message="$(cat)"
|
||||||
|
orig_message="$message"
|
||||||
[ "$message" = "''" ] && exit 0
|
[ "$message" = "''" ] && exit 0
|
||||||
[ -z "$message" ] && exit 0
|
[ -z "$message" ] && exit 0
|
||||||
|
|
||||||
@ -774,14 +775,17 @@
|
|||||||
[ -n "$togroup" ] && room=$togroup
|
[ -n "$togroup" ] && room=$togroup
|
||||||
if ps ax | grep -v grep | grep -q synapse.app.homeserver
|
if ps ax | grep -v grep | grep -q synapse.app.homeserver
|
||||||
then
|
then
|
||||||
if [ -p /usr/local/share/$(hostname).fifo ]
|
if [ -p "/usr/local/share/$(hostname).fifo" ]
|
||||||
then
|
then
|
||||||
echo "$message" >/usr/local/share/$(hostname).fifo
|
matrix_message=$(echo "${subj}<br>${orig_message}")
|
||||||
|
matrix_target="/usr/local/share/$(hostname).fifo"
|
||||||
|
[ -n "$togroup" ] && [ -p "/usr/local/share/$(hostname)-${togroup}.fifo" ] && target="/usr/local/share/$(hostname)-${togroup}.fifo"
|
||||||
|
echo "$matrix_message" >"$target"
|
||||||
else
|
else
|
||||||
sudo /usr/bin/docker compose -f /home/docker/matrix.$(hostname)/docker-compose.yml run -T matrix.$(hostname)--commander -m "$message" -k --room $room --log-level WARNING WARNING
|
sudo /usr/bin/docker compose -f /home/docker/matrix.$(hostname)/docker-compose.yml run -T matrix.$(hostname)--commander -m "$message" -k --room $room --log-level WARNING WARNING
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
## SIGNAL
|
## SIGNAL
|
||||||
if [ -f /home/signal/.local/share/signal-cli/data/accounts.json ]
|
if [ -f /home/signal/.local/share/signal-cli/data/accounts.json ]
|
||||||
|
Loading…
Reference in New Issue
Block a user