Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Comparing changes

Choose two branches to see what's changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
base fork: mperham/sidekiq
...
head fork: sush/sidekiq
compare: master
Checking mergeability… Don't worry, you can still create the pull request.
  • 1 commit
  • 1 file changed
  • 2 commit comments
  • 1 contributor
Showing with 1 addition and 1 deletion.
  1. +1 −1  lib/sidekiq/capistrano.rb
View
2  lib/sidekiq/capistrano.rb
@@ -16,7 +16,7 @@
desc "Start sidekiq"
task :start do
rails_env = fetch(:rails_env, "production")
- run "cd #{current_path} && bundle exec sidekiq -e #{rails_env} -C config/sidekiq.yml -P tmp/pids/sidekiq.pid >> log/sidekiq.log &"
+ run "cd #{current_path} && nohup bundle exec sidekiq -e #{rails_env} -C config/sidekiq.yml -P tmp/pids/sidekiq.pid >> log/sidekiq.log < /dev/null 2>&1 & sleep 1"
end
desc "Restart sidekiq"

Showing you all comments on commits in this comparison.

@mperham
Owner

I think you mean to do this to redirect both stdout and stderr. You don't want to redirect them to /dev/null or you will never see any errors or logging output.

&>> log.sidekiq.log

< /dev/null sets Sidekiq's STDIN to /dev/null.

Also, what is the purpose of the sleep 1?

@sush

Yes my bad, I didn't explain it well :)

About the sleep 1 I don't really know why but without it does not work.

Something went wrong with that request. Please try again.