ryandotsmith / nginx-buildpack

Run NGINX in front of your app server on Heroku
456 stars 783 forks source link

fix race condition #36

Closed yingted closed 9 years ago

yingted commented 10 years ago

I'm experiencing occasional failed deploys when nginx crashes because it couldn't open the logs.

ryandotsmith commented 10 years ago

Interesting... Have you been running this patch for a while? Are you certain this is the fix? It seems plausible, just want to be sure.

yingted commented 10 years ago

Yeah, I've been getting failed deploys with one of two error messages:

  1. Could not open $file (this patch)
  2. Some rails dependency error

Now I'm only getting (2).

polyrabbit commented 9 years ago

@ryandotsmith Would you please merge this PR? I have ran into this problem too. According to my test, bash doesn't run daemonized subshells in sequence, e.g. bash -c '(echo 1)& (echo 2)& (echo 3)&'. Run it several times, and you will see.