OPNsense
  • Home
  • Help
  • Search
  • Login
  • Register

  • OPNsense Forum »
  • English Forums »
  • Web Proxy Filtering and Caching (Moderator: fabian) »
  • Nginx Proxy not working?
« previous next »
  • Print
Pages: [1]

Author Topic: Nginx Proxy not working?  (Read 4350 times)

cclloyd

  • Newbie
  • *
  • Posts: 39
  • Karma: 0
    • View Profile
Nginx Proxy not working?
« on: November 14, 2018, 02:46:03 am »
Here are my settings: https://imgur.com/a/2aa6CRY

I'm trying to use the nginx plugin to add a few proxy addresses to my network.  For example, I want to proxy `nzb.example.com:80` to `10.0.1.11:6789`, but with the above settings, when I go to nzb.example.com, it times out when trying to connect.

Any advice on configuring this plugin?
Logged

fabian

  • Moderator
  • Hero Member
  • *****
  • Posts: 2769
  • Karma: 200
  • OPNsense Contributor (Language, VPN, Proxy, etc.)
    • View Profile
    • Personal Homepage
Re: Nginx Proxy not working?
« Reply #1 on: November 14, 2018, 11:53:22 pm »
The configuration looks almost ok but you have to add the upstream in the location and what probably caused the issue is some kind of a host firewall or routing issue. Please check that with tcpdump.
Logged

cclloyd

  • Newbie
  • *
  • Posts: 39
  • Karma: 0
    • View Profile
Re: Nginx Proxy not working?
« Reply #2 on: November 15, 2018, 01:23:30 am »
Ok I added the upstream server to the location.  I still can't connect.  I doubt its a firewall issue because I'm accessing it on LAN, and ufw is disabled on the machine its trying to proxy to.

I am not familiar with tcpdump, but when I tried to access it in the ssh shell, I couldn't immediately see any useful information.

If it means anything, the page I'm trying to connect to is also protected by a .htpasswd file.
« Last Edit: November 15, 2018, 01:25:54 am by cclloyd »
Logged

fabian

  • Moderator
  • Hero Member
  • *****
  • Posts: 2769
  • Karma: 200
  • OPNsense Contributor (Language, VPN, Proxy, etc.)
    • View Profile
    • Personal Homepage
Re: Nginx Proxy not working?
« Reply #3 on: November 15, 2018, 05:34:31 pm »
if curl -v http://example.com:3456/ from OPNsense is also not working, then you may get some more detailed information.

You can also run the packet capture from the web interface when you are using nginx. You can also use some server in the internet as an upstream server to check if your nginx server configuration works (you should get any site or an foreign error page from that server you have entered).
Logged

  • Print
Pages: [1]
« previous next »
  • OPNsense Forum »
  • English Forums »
  • Web Proxy Filtering and Caching (Moderator: fabian) »
  • Nginx Proxy not working?
 

OPNsense is an OSS project © Deciso B.V. 2015 - 2024 All rights reserved
  • SMF 2.0.19 | SMF © 2021, Simple Machines
    Privacy Policy
    | XHTML | RSS | WAP2