https://github.com/gr1d99/notifications_app
This is the demo app for the medium post that I made (https://medium.com/@giddykim/sending-emails-in-rails-with-sucker-punch-gem-part-1-76b501ad943f)
https://github.com/gr1d99/notifications_app
asynchronous-tasks background-jobs learning-by-doing rails rails-api
Last synced: 11 months ago
JSON representation
This is the demo app for the medium post that I made (https://medium.com/@giddykim/sending-emails-in-rails-with-sucker-punch-gem-part-1-76b501ad943f)
- Host: GitHub
- URL: https://github.com/gr1d99/notifications_app
- Owner: gr1d99
- Created: 2019-06-07T14:25:07.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2023-01-19T13:21:59.000Z (about 3 years ago)
- Last Synced: 2024-04-16T04:23:56.395Z (almost 2 years ago)
- Topics: asynchronous-tasks, background-jobs, learning-by-doing, rails, rails-api
- Language: Ruby
- Size: 35.2 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 9
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# README
## Setup
1. Clone app
2. run `bundle install`
3. run `rake db:create`
4. open `application.rb` and update smtp_settings config
```ruby
config.action_mailer.smtp_settings = {
address: 'smtp.gmail.com',
port: 587,
user_name: '',
password: '',
authentication: 'plain',
enable_starttls_auto: true }
```
Replace `` with your Gmail account address
Replace `` with the password of the email you specified above.
5. Open `app/mailers/application_mailer.rb` and replace `'from@example.com'`with the email address you specified in **step 4**
6. Start server `rails s`
7. Send email notifications by making a post request to `http://localhost:3000/notifications`
```json
{
"notification": {
"content": "hello world",
"recipients": ["your-email@gmail.com"]
}
}
```