Forward local ip/device to local ip AND port


DoeBoye

Recommended Posts

Hello all,

 

My networking skills are limited, and I've been trying for a week now to forward a local ip address/local domain name to another local ip address AND port (In other words, forward 192.168.1.10 to 192.168.1.11:8765, or set up a local dns in my router and forward test.home to 192.168.1.11:9876 ).

 

I have looked at dnsmasq (no port support), ssh tunnels, proxies, port forwarding in my router, local dns servers (bind, the router itself, etc), and just can't seem to figure this out.

 

One caveat is that I don't want to leave the local network (by using a public domain name and router port forwarding). All traffic must stay within the network. When I started this little project, I thought it would be easy peasy, but I can't quite get it.... HELP!!! :)

 

Thanks for any advice thoughts shared!! :)

 

DB.

Link to comment

DNS does not support ports. Hostname file does not support ports.

 

To my understanding, the only way to do that would be to use some kind of proxy server on your network.


Like the Ngnix/LetsEncrypt docker image does for reverse proxying from outside your local network, you could use Ngnix (or something) to do the same thing inside your network.

If this is for use in a browser, I would probably just use a bookmark that includes the port.

Edited by whipdancer
clarification
  • Upvote 1
Link to comment
On 11/13/2018 at 1:13 PM, whipdancer said:

DNS does not support ports. Hostname file does not support ports.

 

To my understanding, the only way to do that would be to use some kind of proxy server on your network.


Like the Ngnix/LetsEncrypt docker image does for reverse proxying from outside your local network, you could use Ngnix (or something) to do the same thing inside your network.

If this is for use in a browser, I would probably just use a bookmark that includes the port.

Hi whipdancer,

 

Thanks for the push in the right direction! I ended up implementing Nginx, and after a bit of a learning curve, I have it set to forward a local domain name to a different port on my Unraid server :).

 

For the curious, my reason for wanting to set this up is that I bought an Amazon Fire HD8 for my kids, and the built-in Parental Control app Freetime only supports apps downloaded from the Amazon store. I use Emby as my media server, and unfortunately, Amazon removed it from their store awhile back, and are being difficult in re-instating it (even though they have Plex...).

 

There are ways around this, most notably by installing an app called GoToApp which allows you to load apps in FreeTime that have been side-loaded in the main profile. You can side-load the Google Play store in an adult profile and then install Emby without issue. Once Emby is side-loaded, you can use GoToApp in the child profile to run it. The only downside is that there's no way to lock it down, so it opens up all sorts of other options for your kiddos (Not to mention the interface of the app is terrible, and might be confusing for little people to use).

 

My next plan was to run it through the browser, which works quite well. The only problem is the Freetime browser is so locked down, that you cannot specify specific ports.

 

Ahha! I thought. I'll just change Emby to port 80, move Unraid's gui to 8008, and point the browser to my Unraid IP. After a few hours of frustration, I came to realize that Emby does not allow you to assign a restricted port. There is a way around it with some console based configuration trickery, but I didn't want to go that route, especially if it got wiped out after every update (Not sure if it would, but there must be a better way!)

 

So that's where I finally got to this point. I'll simply forward an ip or local domain name to the correct port, and problem solved! :).

 

So this totally works. Now unfortunately, I hadn't taken into account the giant bar at the top of the window in the FreeTime browser, and the video is reduced to roughly half the size it would be in the app at full screen (And the kid's browser doesn't seem to allow full screen)...

 

Sigh. In the end, I think I'm just going to use the slightly less comprehensive "Parental Controls" option applied to my own account and let them use the app directly. Not quite as full featured as the FreeTime sandbox, but should still do the trick.

 

PS: I also tried installing Google's Family Link, which works great, but alas, I could not get running properly on the Fire.

 

I'm sure I can't be the only one with one of these for their kids, so if you're trying to run Emby in FreeTime on a Fire HD, until it is re-added to the Amazon store, this solution might be your best bet! :)

 

  • Like 2
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.