added "sender_address" variable

This commit is contained in:
2023-04-01 11:14:03 +02:00
parent abac9630b4
commit c1d3d2b71b
3 changed files with 27 additions and 24 deletions

View File

@@ -9,7 +9,7 @@ mount_point="{{ mount_point }}"
backup_repository="$mount_point/{{borg_repo}}"
borg_password="{{borg_pass}}"
email_recipient="{{admin_mail}}"
sender_address="{{sender_adress}}"
# Mounten des Backup-Ziels
mount_successful=0
@@ -81,5 +81,5 @@ hostname=$(hostname)
mail_subject="Backup-Bericht: $hostname - $(date +'%Y-%m-%d %H:%M:%S')"
mail_body="$backup_result\n"
echo -e "$mail_body$target_usage_warning" | mail -s "$mail_subject" -r "no-reply@homeserver.zernis.ch" "$email_recipient"
echo -e "$mail_body$target_usage_warning" | mail -s "$mail_subject" -r "$sender_address" "$email_recipient"
fi