From: Jimmy Soho <email@example.com>
To: unicorn list <firstname.lastname@example.org>
Date: Wed, 18 Aug 2010 13:39:44 +1000 [thread overview]
Message-ID: <AANLkTikvpbqX9UZjM1tMbZYNqBZGHZGUL9P-JDak49of@mail.gmail.com> (raw)
> In your Capistrano deploy tasks, do you create/update the current
> symlink before you send USR2? You should have the symlink updated
> before sending USR2..
Yes I do.
Meanwhile I've been able to indeed reproduce the issue I was seeing if
I prune releases. This is what I do:
- ls /srv/app/releases shows only:
- stop unicorn
- start unicorn
- deploy new release (same code actually)
- unicorn now has a different PID, /proc/31761/cwd does point to the
latest release directory:
/proc/31761/cwd -> /srv/app/releases/20100818024514
- refresh browser, ok, no issue.
- rm -Rf /srv/app/releases/20100818022900
- deploy another new release
nothing in unicorn.stderr.log, but looking in unicorn.stdout.log it mentions:
/srv/app/releases/20100818022900/Gemfile not found
The unicorn process PID hasn't changed, nor has proc/31761/cwd
My /srv/app/current dir now points to the latest release. Which I
guess is wrong as well, as unicorn failed to start with the latest
release; so it (= capistrano) needs to rollback somehow (which is a
If I now peek in /proc/31761/environ then I notice these:
which are all pointing to the working directory I pruned. Hence the
message about Gemfile not found I guess.
Any suggestions how / when to update those environment variables with
> Other folks here may have more experience with Capistrano+Unicorn,
> maybe they have portable recipes they can share.
Maybe it's more a gem and/or bundler thing? Though it seems like a
general issue to me that environment variables can have references to
old working directories, which need to be updated if you restart
Unicorn with USR2 all the time. Is this something Unicorn could
possibly take care off?
Unicorn mailing list - email@example.com
Do not quote signatures (like this one) or top post when replying
next prev parent reply other threads:[~2010-08-18 3:39 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-08-18 0:02 ` Jimmy Soho
2010-08-18 1:14 ` Eric Wong
2010-08-18 2:23 ` Jimmy Soho
2010-08-18 2:45 ` Eric Wong
2010-08-18 3:39 ` Jimmy Soho [this message]
2010-08-18 7:14 ` Eric Wong
2010-08-18 13:20 ` Jimmy Soho
2010-08-18 23:34 ` Eric Wong
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
List information: https://yhbt.net/unicorn/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).