mirror of
https://github.com/myvesta/vesta
synced 2025-07-05 12:36:23 -07:00
Fix emailadres and subject
This commit is contained in:
parent
66ae5580cd
commit
4acfa26de5
1 changed files with 6 additions and 0 deletions
|
@ -610,6 +610,9 @@ rebuild_pgsql_database() {
|
|||
if [ -z $HOST ] || [ -z $USER ] || [ -z $PASSWORD ] || [ -z $TPL ]; then
|
||||
echo "Error: postgresql config parsing failed"
|
||||
if [ ! -z "$SENDMAIL" ]; then
|
||||
subj="Error: postgresql config parsing failed"
|
||||
email=$($BIN/v-get-user-value admin CONTACT)
|
||||
|
||||
echo "Can't parse PostgreSQL config" | $SENDMAIL -s "$subj" $email
|
||||
fi
|
||||
log_event "$E_PARSING" "$ARGUMENTS"
|
||||
|
@ -621,6 +624,9 @@ rebuild_pgsql_database() {
|
|||
if [ '0' -ne "$?" ]; then
|
||||
echo "Error: Connection failed"
|
||||
if [ ! -z "$SENDMAIL" ]; then
|
||||
subj="Error: Connection failed"
|
||||
email=$($BIN/v-get-user-value admin CONTACT)
|
||||
|
||||
echo "Database connection to PostgreSQL host $HOST failed" |\
|
||||
$SENDMAIL -s "$subj" $email
|
||||
fi
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue