Rails droplet permission issues with no reason

April 5, 2019 321 views
Ruby on Rails Ubuntu 18.04

Hello,

I’m using a Ruby on Rails droplet for a few weeks. Since yesterday, for no reason, my project has no assets (JS/CSS) anymore… Apparently, it could be related to permission issues on the public folder, but I can’t figure out how to access to server logs :/
Is there a way to confirm this problem, and to fix it?
Thank you in advance

1 comment
  • I just figured out how to access Nginx error logs, and here it is:

    cat /var/log/nginx/error.log
    2019/04/08 11:13:46 [error] 890#890: *17990 upstream timed out (110: Connection timed out) while reading response header from upstream, client: 199.229.249.134, server: _, request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:3000/", host: "staging.beweeg.fr"
    2019/04/08 12:54:24 [error] 890#890: *18019 upstream timed out (110: Connection timed out) while reading response header from upstream, client: 93.26.167.237, server: _, request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:3000/", host: "staging.beweeg.fr"
    2019/04/08 15:26:54 [error] 890#890: *18040 upstream timed out (110: Connection timed out) while reading response header from upstream, client: 82.124.121.20, server: _, request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:3000/", host: "staging.beweeg.fr"
    2019/04/08 15:27:53 [error] 890#890: *18045 upstream timed out (110: Connection timed out) while reading response header from upstream, client: 82.124.121.20, server: _, request: "GET /coach/login HTTP/1.1", upstream: "http://127.0.0.1:3000/coach/login", host: "staging.beweeg.fr", referrer: "http://staging.beweeg.fr/"
    2019/04/08 16:22:01 [error] 890#890: *18392 upstream timed out (110: Connection timed out) while reading response header from upstream, client: 82.124.121.20, server: _, request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:3000/", host: "staging.beweeg.fr"
    2019/04/08 16:22:07 [error] 890#890: *18398 upstream timed out (110: Connection timed out) while reading response header from upstream, client: 82.124.121.20, server: _, request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:3000/", host: "staging.beweeg.fr"
    2019/04/08 16:23:09 [error] 890#890: *18398 upstream timed out (110: Connection timed out) while reading response header from upstream, client: 82.124.121.20, server: _, request: "GET /favicon.ico HTTP/1.1", upstream: "http://127.0.0.1:3000/favicon.ico", host: "staging.beweeg.fr", referrer: "http://staging.beweeg.fr/"
    2019/04/08 16:23:40 [error] 890#890: *18405 upstream timed out (110: Connection timed out) while reading response header from upstream, client: 82.124.121.20, server: _, request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:3000/", host: "staging.beweeg.fr"
    2019/04/08 16:23:44 [error] 890#890: *18408 upstream timed out (110: Connection timed out) while reading response header from upstream, client: 82.124.121.20, server: _, request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:3000/", host: "staging.beweeg.fr"
    2019/04/08 17:37:58 [error] 890#890: *18431 upstream timed out (110: Connection timed out) while reading response header from upstream, client: 93.26.167.237, server: _, request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:3000/", host: "staging.beweeg.fr", referrer: "http://staging.beweeg.fr/"
    2019/04/08 20:47:42 [error] 890#890: *18445 upstream timed out (110: Connection timed out) while reading response header from upstream, client: 199.229.249.146, server: _, request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:3000/", host: "staging.beweeg.fr"
    2019/04/08 20:55:09 [error] 890#890: *18452 upstream timed out (110: Connection timed out) while reading response header from upstream, client: 199.229.249.146, server: _, request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:3000/", host: "159.65.207.10"
    2019/04/08 21:13:11 [error] 890#890: *18456 connect() failed (111: Connection refused) while connecting to upstream, client: 93.26.167.237, server: _, request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:3000/", host: "staging.beweeg.fr"
    

    I can’t really understand (noob…). I just restarted the Rails service, after removing node_modules, yarned again, and bundled again… For now the site seems ok, but it is very slow. Locally I have no problem, so I guess I misconfigured something in my droplet? Any help?

    Thx in advance!

Be the first one to answer this question.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!