-
Notifications
You must be signed in to change notification settings - Fork 0
feat: Implement Mass Announcement Features through AWS SES #9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
e51a3b0 to
1971a82
Compare
jinyoungbang
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@cwgough I can't seem to request changes but feel free to look over the comments!
|
|
||
|
|
||
| # why is GET needed? | ||
| @announcements_routes.route("/announcement", methods=["GET", "POST"], cors=True) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think GET isn't needed in this case – just have POST!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| return f'Sent emails to {len(emails)} people: {emails}' | ||
|
|
||
|
|
||
| # @announcements_routes.route("/test-email") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
and if the above works, feel free to get rid of this!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just changed it so you can test just the backend (otherwise the request is empty and no data is sent) so I'll leave it
| load_dotenv() | ||
|
|
||
| mongo_admin_user = os.getenv('MONGO_ADMIN_USER') | ||
| mongo_admin_password = os.getenv('MONGO_ADMIN_PASSWORD') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So I attempted a test by manually inputting env variables on our chalice lambda application, but whenever it deploys it, it seems to reset and deletes it to the default config.json variables.
There seems to be a AWS service called Systems Manager Parameter Store (https://docs.aws.amazon.com/systems-manager/latest/userguide/systems-manager-parameter-store.html) and I think I can try give this an attempt on this branch so we can directly call the env vars on the cloud instead!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds good. I can't tell if you have to do this, because I can create a parameter; but I'm not sure if I would be able to deploy it on our app. This does look like the expected solution, though: I think we would just replace our .env with the parameter store and be good to go.
What does this PR do?
This PR implements the feature to send mass announcements to PCT members using AWS.
TODOs:
Type of change
Tests Performed
Screenshots
Additional Comments