[GH-ISSUE #875] Help Forwarding to LAN #741

Closed
opened 2026-02-26 06:34:13 +03:00 by kerem · 1 comment
Owner

Originally created by @mikeymop on GitHub (Feb 7, 2021).
Original GitHub issue: https://github.com/NginxProxyManager/nginx-proxy-manager/issues/875

Checklist

What is troubling you?

I am running OMV 5.0 on a machine at port 90. This machine is running docker, which in turn is running npm.
My machine is located on my lan at 192.168.1.180 and my router is forwarding ports 80, 81, 443 to 192.168.1.180.

Screen Shot 2021-02-10 at 10 26 08 AM

I am running a few services on docker, for example portainer, which I can reach from my lan at 192.168.1.180:9000.

My dns provider, fowards the following

  • A: subdomain.domain.com -> [external ip address]
  • CNAME: portainer -> callisto.domain.com

Side note: This configuration works for another docker host I have running on digitalocean, I want to bring these benefits to my own server running at home.

If I docker exec into my npm container, I can ping 192.168.1.180 so I know that the npm container can see my host.
In the npm gui, I tried to add a host portainer2.domain.com and forward it to 192.168.1.180 port 9000. I then flushed my dns cache and tried to browse to it. This results in a 404 error.

I then used docker inspect to find:

"Gateway": "172.18.0.1",
"IPAddress": "172.18.0.2",

I have adjusted portainer2.domain.com to forward to both 172.18.0.1 port 9000 and 172.18.0.2 port 9000 and I get the same result.

The only other solution I can think of, is adding CNAME records and port forward entries for each one of my services so that I can forward to cname.domain.com however this is suboptimal because I would like to keep all of these ports closed on my router and funnel everything through 80, 443, and 81.

Is there something I am missing in order to configure npm to forward external requests through my lan to the correct service?

Additionally, if it can work this way, I would like to also forward to subdomain to OMV which is running directly on my host (and not in docker) which is located at 192.168.1.180:90, since npm can see 192.168.1.180 I presume this would be possible however I have also not been able to get that to work.

TLDR

What am I missing in order to correctly have npm (in docker) forward external requests through my lan to the correct service running on my host located at 192.168.1.180.

Do I have to also forward ports from my router for each individual server?

Originally created by @mikeymop on GitHub (Feb 7, 2021). Original GitHub issue: https://github.com/NginxProxyManager/nginx-proxy-manager/issues/875 **Checklist** - Please read the [setup instructions](https://nginxproxymanager.com/setup/) - Please read the [FAQ](https://nginxproxymanager.com/faq/) **What is troubling you?** I am running OMV 5.0 on a machine at port 90. This machine is running docker, which in turn is running npm. My machine is located on my lan at `192.168.1.180` and my router is forwarding ports 80, 81, 443 to `192.168.1.180`. <img width="905" alt="Screen Shot 2021-02-10 at 10 26 08 AM" src="https://user-images.githubusercontent.com/4002969/107531267-a7372500-6b8a-11eb-910d-e2b166113296.png"> I am running a few services on docker, for example portainer, which I can reach from my lan at `192.168.1.180:9000`. My dns provider, fowards the following * `A: subdomain.domain.com -> [external ip address]` * `CNAME: portainer -> callisto.domain.com` Side note: This configuration works for another docker host I have running on digitalocean, I want to bring these benefits to my own server running at home. If I `docker exec` into my npm container, I can ping `192.168.1.180` so I know that the npm container can see my host. In the npm gui, I tried to add a host `portainer2.domain.com` and forward it to `192.168.1.180` port `9000`. I then flushed my dns cache and tried to browse to it. This results in a 404 error. I then used `docker inspect` to find: ```json "Gateway": "172.18.0.1", "IPAddress": "172.18.0.2", ``` I have adjusted `portainer2.domain.com` to forward to both `172.18.0.1` port `9000` and `172.18.0.2` port `9000` and I get the same result. The only other solution I can think of, is adding CNAME records and port forward entries for each one of my services so that I can forward to `cname.domain.com` however this is suboptimal because I would like to keep all of these ports closed on my router and funnel everything through 80, 443, and 81. Is there something I am missing in order to configure npm to forward external requests through my lan to the correct service? Additionally, if it can work this way, I would like to also forward to subdomain to OMV which is running directly on my host (and not in docker) which is located at `192.168.1.180:90`, since npm can see `192.168.1.180` I presume this would be possible however I have also not been able to get that to work. #### TLDR What am I missing in order to correctly have npm (in docker) forward external requests through my lan to the correct service running on my host located at `192.168.1.180`. Do I *have* to also forward ports from my router for each individual server?
kerem 2026-02-26 06:34:13 +03:00
Author
Owner

@mikeymop commented on GitHub (Feb 10, 2021):

Marking this resolved, the issue was that my router was blocking loopbacks.
I found I was able to reach my hosts when outside of my LAN, however when inside of my LAN the requests were still blocked.

It turns out the Verizon G1000 Quantum Gateway blocks loopback requests and there is not an easy way to resolve this on the router itself.

<!-- gh-comment-id:776833177 --> @mikeymop commented on GitHub (Feb 10, 2021): Marking this resolved, the issue was that my router was blocking loopbacks. I found I was able to reach my hosts when outside of my LAN, however when inside of my LAN the requests were still blocked. It turns out the Verizon G1000 Quantum Gateway blocks loopback requests and there is not an easy way to resolve this on the router itself.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/nginx-proxy-manager-NginxProxyManager#741
No description provided.