ruby on rails - Puma is not working with nginx in ROR -
i using command manually
bundle exec puma -e production -b unix:///var/www/rails_apps/agarcents/shared/tmp/sockets/puma.sock
my server working fine. i'm able access url when bind socket nginx, i'm unable access server.
my nginx configuration is
upstream puma_agarscents { server unix:/var/www/rails_apps/agarcents/shared/tmp/sockets/puma.sock fail_timeout=0; } server { listen 80; server_name x.x.x.x; # change match url root /var/www/rails_apps/agarcents/current/public; listen 443 ssl; location / { proxy_pass http://puma_agarscents; proxy_set_header host $host; proxy_set_header x-forwarded-for $proxy_add_x_forwarded_for; } ssl_certificate /etc/nginx/ssl/nginx.crt; ssl_certificate_key /etc/nginx/ssl/nginx.key; location ~* ^/assets/ { # per rfc2616 - 1 year maximum expiry expires 1y; add_header cache-control public; # browsers still send conditional-get requests if there's # last-modified header or etag header if haven't # reached expiry date sent in expires header. add_header last-modified ""; add_header etag ""; break; } }
getting below error
2015/05/14 05:34:31 [error] 6802#0: *79 connect() unix:/var/www/rails_apps/agarcents/shared/tmp/sockets/puma.sock failed (11: resource temporarily unavailable) while connecting upstream, client: x.x.x.x, server: x.x.x.x, request: "get /favicon.ico http/1.1", upstream: "http://unix:/var/www/rails_apps/agarcents/shared/tmp/sockets/puma.sock:/favicon.ico", host: "x.x.x.x"
Comments
Post a Comment