首页 > 解决方案 > 使用托管在弹性 beantalk 上的 django 站点设置 aws ses

问题描述

我正在尝试使用 amazon ses 为使用弹性 beanstalk 部署的 django 站点发送用户验证电子邮件。

我有 allauth 管理用户注册,并使用 anymail 来管理电子邮件。

我已在 namecheap(托管域)成功完成 DKIM 设置

我收到了一个与权限相关的错误,任何建议表示赞赏:

AnymailAPIError at /accounts/signup/
An error occurred (AccessDenied) when calling the SendRawEmail operation:
User `arn:aws:sts::873836696822:assumed-role/aws-elasticbeanstalk-ec2-role/i-0ce34e11fac257334' 
is not authorized to perform `ses:SendRawEmail' on resource `arn:aws:ses:us-west-2:873836696822:identity/newuser@testing.com'

botocore.exceptions.ClientError: An error occurred (AccessDenied) when calling the SendRawEmail operation:
User `arn:aws:sts::873836696822:assumed-role/aws-elasticbeanstalk-ec2-role/i-0ce34e11fac257334' 
is not authorized to perform `ses:SendRawEmail' on resource `arn:aws:ses:us-west-2:873836696822:identity/newuser@testing.com'

标签: djangoamazon-web-servicesamazon-sesdjango-anymail

解决方案


推荐阅读