• dj.god

    defunkt 18 Nov 2008

    People have asked for our delayed_job god config.

    Welp, here it is:

  • Comments

    joergbattermann Sat Dec 27 22:08:24 -0800 2008

    Quick Q regarding this… does delayed_job ever go out of the ‘init’ phase (god status etc wise)?

    Apparently the rake task ain’t daemonized or anything and here it never reaches the ‘up’ state…

    evanwhalen Tue May 19 05:55:44 -0700 2009

    This rake task runs in the root directory, so I had to specify the path to rails root in the rake libdir option to get this to work
    w.start = "rake -f #{rails_root}/Rakefile -I #{rails_root} RAILS_ENV=production jobs:work"

    prefixing the start command with "cd #{rails_root} && rake..." will not work because this command appears to create two processes causing god to monitor the first process (which is caused by the cd command?) and not the rake command. Using this approach will continually add a new rake process every time god is restarted (you'll want to "sudo god restart dj" on every deploy).

    This may be obvious, but a good way to debug this is to just run this rake task (as your app user) directly on the server to make sure the rake task isn't failing.

    sandrods Fri Jul 24 09:25:05 -0700 2009

    Sorry for my ignorance, but why do you need 20 watches for the same processes (20.times do...)??. I really don`t get it.

    blakewatters Sun Jul 26 20:57:26 -0700 2009

    @sandrods That is for 20 separate worker instances

    bosta Tue Oct 20 06:04:28 -0700 2009

    Great post I like it thanks for sharing
    free online games
    regards,

    alice1 Thu Nov 05 03:00:12 -0800 2009

    Some useful piece of info thanks!
    logo design

    Please log in to comment.