Skip to content

Cron job not running with when ever.. #655

Open
@anilmagapu

Description

@anilmagapu

Hi there,
I am using rails 3 application ,with that i would like to schedule task using whenever in every minute .but it is not working and no issues getting .plase help me.

Source :
Added gem in gemfile: gem 'whenever', :require => false
wheneverize .

schedule.rb

every 1.minute do
    command "echo 'one' && echo 'two'"
    runner "CollEmployTransactionHpEntry.some_method", :environment => "development"
end

crontab -l

* * * * * /bin/bash -l -c 'echo '\''one'\'' && echo '\''two'\'''

* * * * * /bin/bash -l -c 'cd /home/nyros/Documents/Projects/PPFC/Augest/8/Telecaller/PPFC && bundle exec script/rails runner -e development '\''CollEmployTransactionHpEntry.some_method'\'''

Thanks & Regards,
Anil

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions