resolving docker ip:port to a friendly name on my home network


daniel.boone

Recommended Posts

Wondering how the community is approaching this? I've been looking at reverse proxies but it seems those are intended to make microservices resolvable publicly. While purchasing a domain might make it easier I'm not looking to share these publicly. My goal is to make a series of docker services more accessible to family members. 

 

I found this recently, no association to me, https://github.com/cristianoliveira/ergo. Wanted to see how others have approached this problem.

Link to comment

This is fairly easy if you are running your own local dns server (not the resolver only, a real server).

Your zone should exist twice, one on the external server, one on the internal.

They need not to be identical! (in most cases they should and would, but this is not totally necessary).

 

The internal server keeps the local adresses like

             www in A 192.168.0.1

whereas the external server contains your global ones like

              www in A 1.2.3.4

 

Point your internal resolvers to use your internal server (and tell him to forward everything it does not know himself to somebody more clever like google or cloud9 or something).

 

Now install "nginx proxy server official" on your unraid box.

 

create a new entry in your internal dns zone like

              webcam in CNAME UnraidBox.mydomain.xxx.

(take care of the "." at the end! it is critical!)

 

Create a new proxyhost in your nginx proxy server with the name "webcam" and the host of your real webcam and the port that you need.

 

Now you can tell your family to use webcam.mydomain.xxx to go to the correct ip and port.

From the internet it is not useable. The name "webcam" is simply not known. If you want to make it available you have to add it to the external zone file too.

 

(maybe "webcam" was not the brightest example because they usually do not run on HTTP Protocol, but you did not tell us, WHAT you want to use, so just substitute it with your demands).

 

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.