rails 500 error no production log entry

2019-05-30 14:55发布

问题:

I have installed a new rails application on the same server as another application. The original is running fine but the new application gives me the infamous "We're sorry but something went wrong" but there is no entry in production log. The last entries in production log are from my migration using rake.

I have found if I run cap deploy:cold it will work but then on the next yupdate will fail again with no sock file. Then cap deploy:cold seems to be required on each update.

edit: If I run /etc/init.d/unicorn_taxidata restart I get "couldn't reload" then if I run it again immediately it starts fine.

The app works in development. Environment is NGINX, unicorn, postgresql, rails 4.0.0.0, ruby 2.0.0p195.

I have this error in my nginx error log:

[crit] 889#0: *65 connect() to unix:/tmp/unicorn.myapp.sock failed (2: No such file or directory) while connecting to upstream, client: 1.123.13.26, server: myapp.com.au, request: "GET /login HTTP/1.1", upstream: "http://unix:/tmp/unicorn.myapp.sock:/login"