Rails one-click (16.04) problem with unicorn.sock not found

June 15, 2017 245 views
Ruby on Rails Nginx Ubuntu 16.04

I'm trying to setup my Rails app onto the new one-click install using Ubuntu 16.04. I was trying to set Let's encrypt when I realize the server did not work and the nginx log show me this:

2017/06/15 10:49:17 [crit] 3304#3304: *1 connect() to unix:/run/DigitalOceanOneClick/unicorn.sock failed (2: No such file or directory) while connecting to upstream, client: x.x.x.x, server:, request: "GET /favicon.ico HTTP/1.1", upstream: "http://unix:/run/DigitalOceanOneClick/unicorn.sock:/favicon.ico", host: "", referrer: ""

Checking at the /run folder, it seems that DigitalOceanOneClick directory is erased somehow. Whenever I create it, something erase it.

Here are the thing I did on the machine (the rails_project demo page was working fine before):

  • Use rvm to change Ruby version (was 2.4.0 but needed to change to 2.2.5)
  • Install my app and its dependencies (every worked out)
  • Point unicorn to the right directory (the new app)
  • Configure nginx to point to the right directory and start let's encrypt but then it failed to find well-known... public URL

Anyone of you experiencing that?

3 Answers

i have the same issue. it's very strange

With the previous one-click setup for Rails (on Ubuntu 14.04), it was much easier to manage Ruby and its Gems. Right now, as soon as I'm trying to change Ruby version and restart unicorn and nginx, the same error appear, the server crash and I cannot seem to be able to make it work again.
Any member of the team will be available to give some insight or help? or should I open a priority ticket with the support team?

I got same issue. Have you able to resolve this issue ?

Have another answer? Share your knowledge.