Whenever gem doesn't run on production
Nobody has claimed this yet.
- Dominant language
- Ruby
- Stars
- 8.9k
- Forks
- 715
- PR merge metrics
- No merged PRs in 30d
Description
I have whenever installed on my Rails 4.2.4 application and want to run this command:
rake punching_bag:combine[14,3,2] for punching_bag gem.
punching_bag gem is a hit tracker & this command combines all posts hits for better performance.
My schedule.rb looks like this:
every 1.day, :at => '3:30 am' do
rake "punching_bag:combine[2,3,2]"
end
When I run crontab -e in my server Ubuntu 12, I can see the cron job:
30 3 * * * /bin/bash -l -c 'cd /home/productiondeploy/mydomain/releases/201611107983652 && RAILS_ENV=production bundle exec rake punching_bag:combine --silent'
But I can see that the command is not running and posts hits are Not combined. Is it something I do wrong here and how to fix it?
Thanks in advanced!
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with schedule.rb and the generated crontab entry shown in the report; run the exact production bundle exec rake command manually, then compare its environment and output with cron execution. Done means the scheduled punching_bag:combine task runs in production and combines the post hits.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- bash, rails, ruby, ubuntu
- Domain
- backend, devops
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100