[Solved] How to prevent a docker container to get a IPv6?


Recommended Posts

Hi, sorry for all those strange questions.

I had a problem to get IPv6 to a docker container (Plex for external use).

Now after many trial an error it's done! 

But now every container uses ipv6. 

One special container shouldn't get one. SABnzbd+vpn. I think it is obvious why this container shouldn't get a global IPv6.

Perhaps it is possible to block by using custom and not host or bridge?

If i put in only a IPv4 it get a IPv6 automatically.

Is there a command for blocking it? Put in a IPv4, and then a command or something like that?

 

Edited by Schicksal
Link to comment
1 hour ago, Schicksal said:

Sorry but does it mean docker doesn’t need IPv6 support and I could mapp a port from unraid itself (which have a global IPv6) to the Plex dock to get external access? That would make things easier.
I need IPv6 because I only have global IPv6, no IPv4.

Yep. For local networking, IPv6 is a liability (e.g. VPN leaks) and much harder to deal with (e.g. 192.168.0.1 is a lot easier to remember than blablabla:blablabla:blablabla:blablabla).

 

And in terms of port-forwarding, it depends on your router but it's pretty normal to have Internet <--- IPv6 ---> router <--- IPv4 ---> docker. Internet-router and router-device are 2 independent networks.

 

Edited by testdasi
Link to comment

This is the current status:

My router has a global IPv6

1. picture

 

My Tower "P...." has a global IPv6

2. picture

 

And I'm using the global IPv6 of the Tower to connect to Port 32400 for Plex.

 

Do I unsterstand it correctly?

- I disable the docker ability for IPv6

- the Plex container get a fixed IPv4 (custom...blah for example 10.0.0.11)

- I put a portforwarding on 10.0.0.11 for port 32400

- I connect from external to the IPv6 of my router with port 32400?

 

or I put the Plex container to bridge(?) or host(?) and I configure a portforwarding to 10.0.0.10 (IPv4 of my tower)?

 

PS: sorry, i don't know how to put the pictures on the right place.

Bildschirmfoto 2020-08-25 um 13.03.13.png

Bildschirmfoto 2020-08-25 um 12.56.27.png

Bildschirmfoto 2020-08-25 um 12.58.06.png

Link to comment

For me i use the unraid ip and port 32400 in router settings

 

Need to port it to the internal 32400 aswell, You can try change external port on plex to somthing else personaly i changed to 50000 on mine. Since i had problems connecting to my plex when i had it on 32400

 

 

 

 

 

 

 

 

 

 

Link to comment

thanks a lot testdasi and Ronhj. i'll try this.

i thoght i "only" need to learn about linux and this docker stuff.

the most time in the last weeks i read and learned so many things about network 

 

——edit——

 

Nope. Not working like this with my hardware.

I think the AVM Fritzbox cannot translate from IPv6 to IPv4. It feels like only working with IPv6 Ports to IPv6 Ports and IPv4 Ports to IPv4 Ports.

It’s only working with an IPv6 on the unraidserver.

So I still need to block some containers to get a IPv6 address.

 

 

-------edit----------

this worked for me, if some interested in:

--sysctl net.ipv6.conf.all.disable_ipv6=1

Edited by Schicksal
  • Like 1
  • Thanks 1
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.