502 Bad Gateway

Ben wrote...
Hi All,

When accessing the web server through the servers IP in a browser, I'm getting '502 Bad Gateway'

Any advice? I'm following the Digital Ocean installation guide

Thank,s

Ben
Flag for Review
      Scott Miller replied...
      Hmm that sounds like a problem with nginx not proxying through to unicorn. Here is what I have for each of my config files:

      nginx: https://gist.github.com/scott/f76a95040c98763d86bf
      uncorn: https://gist.github.com/scott/98644c4e188210221c23
      unicorn.conf: https://gist.github.com/scott/96512f9c8a2ed54495f3

      Check and make sure your configs are similar. If that doesn't help, let me know.

      Scott
      Flag for Review
          Scott Miller replied...
          This also happens when Unicorn is not accepting connections. Another possible reason for this is if you need to run bundle install. To make sure, move to the directory where you have Helpy installed and execute 'bundle install'

          Scott
          Flag for Review
              Pj replied...
              I too have this issue. I re-ran bundle install and no changes in behavior. Any other ideas?

              Just to clarify, I followed this tutorial:

              Installing Helpy on Ubuntu 16.04 using Passenger and Nginx
              https://github.com/helpyio/helpy/wiki/Installing-Helpy-on-Ubuntu-16.04-using-Passenger-and-Nginx

              The only step I do differently is that I create a new config file and used a subdomain like so: support.mysite.com instead of localhost.
              Flag for Review
                  Pj replied...
                  PS - I did not see any reference to unicorn in that tutorial. Is it possibly outdated? Should I follow a different tutorial? I did notice that the nginx config differs in the tutorial and the linked gist.
                  Flag for Review
                      Scott Miller replied...
                      There used to be a guide for installing using Unicorn and the Digital Ocean Rails image. That one is no longer around- installing from scratch is more secure.
                      Flag for Review