commit d4fa33b233a63586b628e8c943874184c5de1dd8 Author: idanoo Date: Fri Nov 11 10:08:44 2022 +1300 Add initial code diff --git a/destination.json b/destination.json new file mode 100644 index 0000000..f6e3d9f --- /dev/null +++ b/destination.json @@ -0,0 +1,5 @@ +{ + "ToAddresses": ["test@test.com"], + "CcAddresses": [], + "BccAddresses": [] +} diff --git a/message.json b/message.json new file mode 100644 index 0000000..15423c6 --- /dev/null +++ b/message.json @@ -0,0 +1,16 @@ +{ + "Subject": { + "Data": "Test email sent using the AWS CLI", + "Charset": "UTF-8" + }, + "Body": { + "Text": { + "Data": "This is the message body in text format.", + "Charset": "UTF-8" + }, + "Html": { + "Data": "This message body contains HTML formatting. It can, for example, contain links like this one: Amazon SES Developer Guide.", + "Charset": "UTF-8" + } + } +} diff --git a/send.sh b/send.sh new file mode 100644 index 0000000..479bedb --- /dev/null +++ b/send.sh @@ -0,0 +1,9 @@ +#!/bin/bash + +PROFILE=$1 +FROM=$2 + +for i in {1..100} +do + aws ses --region us-west-2 --profile $PROFILE send-email --from $FROM --destination file://destination.json --message file://message.json +done