0

I have this resque job that must run at 6 AM or 11 AM or 16 PM or 20 PM o clock

or at least for example 6 am

Resque.enqueue_at <what to put here>, SendSmsJob

How do I define specific time like that? thanks

Kris MP
  • 2,305
  • 6
  • 26
  • 38

1 Answers1

0

You can pass it a Time and it'll run once that time is in the past, like so:

time = Time.new(2016, 6, 11, 20, 0)
Resque.enqueue_at time, SendSmsJob
Lesleh
  • 1,665
  • 15
  • 24