-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
502 bad gateway #38
Comments
sudo tail -30 /var/log/nginx/error.log |
Didn't mean to close it. |
It looks like the Nginx configuration was set up with "remotely.example.com" as the host name. The host name needs to be an actual URL/IP that points to the machine/VM, or the connection will be rejected. This is true for any Nginx server that wants to host multiple sites on one machine (not just a Remotely thing). Since I don't know ahead of time if you intend to host multiple sites, it's configured to only accept traffic for a specific host name. You can manually change the Nginx configuration to "catch all" if you'd prefer that. |
I whitelisted the private info.... Sorry I should of specified. |
Let me give you a better description. I deployed a brand new install of Ubuntu of 18.04 |
Sorry for the misunderstanding. I get a lot of emails where people literally enter "example.com," so I just assumed. My bad. I just tested deploying on a fresh VM, and all went smoothly. Could you try checking the output of the following? nginx -t What are the results of those? |
remotely@remotely:~$ sudo nginx -t remotely@remotely:~$ systemctl status remotely Jun 27 06:56:12 remotely systemd[1]: /etc/systemd/system/remotely.service:5: Working directory path Jun 27 06:56:12 remotely systemd[1]: /etc/systemd/system/remotely.service:5: Working directory path '' is not absolute. remotely@remotely:~$ wget --spider localhost:5000 remotely@remotely:~$ wget --spider localhost:80 remotely@remotely:~$ wget --spider localhost:443 |
It looks like the service isn't starting because the WorkingDirectory is blank (which means ExecStart is likely incorrect as well). The first prompt of the install script asks for the root path where the app is installed (i.e. where the Remotely_Server.dll is located). I might want to make the prompt a little more clear. It sets it in the service file like so:
Check your service config (/etc/systemd/system/remotely.service) and make sure those values have the absolute path in them. Let me know if that was it. :) |
Actually, looking at this again, that variable is used for several other commands. You might just want to run the script again if that variable was indeed blank. |
Here is a video of what I am doing during the re-run of the script. This link expires in 1 day. We aren't using this in production or anything. Its for my homelab I just work from home so it was easier to send it this way. |
When it's asking for the app path, it looks like you're entering an empty string. It's expecting the absolute path to where you want to install the app/website. See here: https://lucency.co/ImageShare/?view=lvwjryji1p2 That path is stored in a variable and used throughout the rest of the script. |
10/10 User error. Works now! Thanks! I thought when it mentioned "typically /var..." that was the default and if you wanted something different please enter it now. Bad on me for making the assumption. |
No problem! Now that you mention it, I think someone else gave me similar feedback once. I added that as the "default" location, so it behaves you described above. Thanks! |
Deployed on ubuntu 18.04 and ran the setup sh but I get 502 bad gateway.
The text was updated successfully, but these errors were encountered: