mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-07-20 09:46:06 +02:00
Update yaml to include metadata, readme with new directions an
d pseudocode for s3 and SES work
This commit is contained in:
parent
2817a3ed5b
commit
fb1735e23f
4 changed files with 85 additions and 4 deletions
|
@ -41,6 +41,7 @@ def send_templated_email(template_name: str, subject_template_name: str, to_addr
|
|||
raise EmailSendingError("Could not access the SES client.") from exc
|
||||
|
||||
try:
|
||||
#if not attachment:
|
||||
ses_client.send_email(
|
||||
FromEmailAddress=settings.DEFAULT_FROM_EMAIL,
|
||||
Destination={"ToAddresses": [to_address]},
|
||||
|
@ -51,5 +52,8 @@ def send_templated_email(template_name: str, subject_template_name: str, to_addr
|
|||
},
|
||||
},
|
||||
)
|
||||
# else: # has attachment
|
||||
# same as above but figure out how to attach a file
|
||||
# via boto3 "boto3 SES file attachment"
|
||||
except Exception as exc:
|
||||
raise EmailSendingError("Could not send SES email.") from exc
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue