0

I am trying to implement an automatic email system within my ruby on rails application that will email users 1 week and 1 day before their password expires. We have implemented devise for the login screen.

What is the best way to approach this using Windows OS?

J.Doe
  • 1
  • 1
  • 1
    This has nothing to do with your OS, first of all. To get the behavior you're describing, I would add `delayed_job` to the app and schedule/remove a job to invoke ActionMailer at the time when you want to send the reminder. Alternatively, you could use a task scheduler to check for cases of upcoming expirations every few minutes then send an email. In this case, you'll need to mark a reminder has been sent and manage that, and also consider what happens if this is a multi-instance application. I recommend method 1 for a prod app, but method 2 for a class assignment for example. – Joe Essey Nov 03 '16 at 20:49
  • @JoeEssey I only mentioned the OS because I researched and found Cron as an option but saw that it was mainly for Unix OS. Thank you for your input. – J.Doe Nov 03 '16 at 21:59
  • You can use https://github.com/jmettraux/rufus-scheduler if you intend to run locally on your machine with 1 instance of the app. You're able to use cron style scheduling. Also, you can usually find the 'Windows app that does x' for example, http://stackoverflow.com/questions/132971/what-is-the-windows-version-of-cron – Joe Essey Nov 04 '16 at 13:53

0 Answers0