Skip to content

Commit

Permalink
fix tools/emailnotify.sh AWS SES routine cc/bcc detection in 123.09be…
Browse files Browse the repository at this point in the history
…ta01
  • Loading branch information
centminmod committed Sep 18, 2020
1 parent 5c0ec5c commit 7dc3ce0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion centmin.sh
Expand Up @@ -27,7 +27,7 @@ DT=$(date +"%d%m%y-%H%M%S")
branchname='123.09beta01'
SCRIPT_MAJORVER='1.2.3'
SCRIPT_MINORVER='09'
SCRIPT_INCREMENTVER='590'
SCRIPT_INCREMENTVER='591'
SCRIPT_VERSIONSHORT="${branchname}"
SCRIPT_VERSION="${SCRIPT_VERSIONSHORT}.b${SCRIPT_INCREMENTVER}"
SCRIPT_DATE='31/07/2020'
Expand Down
8 changes: 3 additions & 5 deletions tools/emailnotify.sh
Expand Up @@ -109,12 +109,12 @@ send_ses_mail() {
email_date=$(date)
SES_FROM_DOMAIN=$(echo "$EMAILNOTIFY_SES_FROM_EMAIL" | awk -F '@' '{print $2}')
if [ "$EMAILNOTIFY_SES_CC_EMAIL" ]; then
ses_cc="Cc: $EMAILNOTIFY_SES_CC_EMAIL"
ses_cc="\nCc: $EMAILNOTIFY_SES_CC_EMAIL"
else
ses_cc=
fi
if [ "$EMAILNOTIFY_SES_BCC_EMAIL" ]; then
ses_bcc="Bcc: $EMAILNOTIFY_SES_BCC_EMAIL"
ses_bcc="\nBcc: $EMAILNOTIFY_SES_BCC_EMAIL"
else
ses_bcc=
fi
Expand All @@ -127,9 +127,7 @@ MAIL FROM: ${EMAILNOTIFY_SES_FROM_EMAIL}
RCPT TO: ${EMAILNOTIFY_SES_TO_EMAIL}
DATA
From: $EMAILNOTIFY_SES_FROM_EMAIL <${EMAILNOTIFY_SES_FROM_EMAIL}>
To: ${EMAILNOTIFY_SES_TO_EMAIL}
$ses_cc
$ses_bcc
To: ${EMAILNOTIFY_SES_TO_EMAIL}${ses_cc}${ses_bcc}
Subject: $subject $email_date
$body
Expand Down

0 comments on commit 7dc3ce0

Please sign in to comment.