Skip to content

Instantly share code, notes, and snippets.

@alexishida
Created August 9, 2022 16:10
Show Gist options
  • Select an option

  • Save alexishida/cf64a3f9de085c903aeb53a6758509ae to your computer and use it in GitHub Desktop.

Select an option

Save alexishida/cf64a3f9de085c903aeb53a6758509ae to your computer and use it in GitHub Desktop.
schedule.rb cron gem whenever rails
env :PATH, "/opt/oracle/instantclient_12_2:#{ENV['PATH']}"
env :LD_LIBRARY_PATH, '/opt/oracle/instantclient_12_2'
env :GEM_PATH, ENV['GEM_PATH']
ENV.each { |k, v| env(k, v) }
env :RAILS_ENV, ENV['RAILS_ENV']
# env :PATH, ENV['PATH']
set :output, error: 'log/whenever_error.log', standard: 'log/whenever.log'
every '20 10 2 * *' do
runner 'Job.run'
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment