all template rewritten, some guesswork

This commit is contained in:
mag37
2024-10-07 21:28:31 +02:00
parent e5a7a715c6
commit ac10a96cc8
10 changed files with 28 additions and 36 deletions

View File

@@ -5,20 +5,15 @@
# Modify to fit your setup - if API, set AppriseURL to your Apprise ip/domain.
send_notification() {
Updates=("$@")
[ -s "$ScriptWorkDir"/urls.list ] && UpdToString=$( releasenotes ) || UpdToString=$( printf "%s\n" "${Updates[@]}" )
[ -s "$ScriptWorkDir"/urls.list ] && releasenotes || Updates=("$@")
UpdToString=$( printf '%s\\n' "${Updates[@]}" )
FromHost=$(hostname)
printf "\nSending Apprise notification\n"
MessageTitle="$FromHost - updates available."
# Setting the MessageBody variable here.
read -d '\n' MessageBody << __EOF
Containers on $FromHost with updates available:
$UpdToString
__EOF
MessageBody=$(printf "🐋 Containers on $FromHost with updates available: \n$UpdToString")
# Modify to fit your setup:
apprise -vv -t "$MessageTitle" -b "$MessageBody" \