Jump to content

Localhost?


johnodon

Recommended Posts

I'm not sure if I could be doing things better but...

 

Each of my containers that interacts with another container (i.e. Sonarr + SAB), I have to connect via IP rather than localhost.

 

For example, in Sonarr Settings --> Download Client --> SabNZBd

 

I have to set Host = 192.168.1.10 (my unraid server addy)

rather than Host = localhost (or 127.0.0.1)

 

Is there a way to have Docker see all of the containers as being on the same host?  I am going to guess it has something to do with IP scheme (NAT vs. bridge vs. whatever) but I just don't know enough about that stuff.

 

After saying all of that, is there really any benefit?  I guess I see the fact that I have to specify the unraid server addy sends the traffic between containers in and out of the network.

 

John

 

EDIT:  Forgot to mention that my data mount point is consistent across all of my containers:  /mnt/ --> /mnt/

 

Link to comment

I'm not sure if I could be doing things better but...

 

Each of my containers that interacts with another container (i.e. Sonarr + SAB), I have to connect via IP rather than localhost.

 

For example, in Sonarr Settings --> Download Client --> SabNZBd

 

I have to set Host = 192.168.1.10 (my unraid server addy)

rather than Host = localhost (or 127.0.0.1)

 

Is there a way to have Docker see all of the containers as being on the same host?  I am going to guess it has something to do with IP scheme (NAT vs. bridge vs. whatever) but I just don't know enough about that stuff.

 

After saying all of that, is there really any benefit?  I guess I see the fact that I have to specify the unraid server addy sends the traffic between containers in and out of the network.

 

John

 

EDIT:  Forgot to mention that my data mount point is consistent across all of my containers:  /mnt/ --> /mnt/

 

I have all mine communicating via "localhost:port" and also running on "host" network config.

 

Works fine.

Link to comment

I'm not sure if I could be doing things better but...

 

Each of my containers that interacts with another container (i.e. Sonarr + SAB), I have to connect via IP rather than localhost.

 

For example, in Sonarr Settings --> Download Client --> SabNZBd

 

I have to set Host = 192.168.1.10 (my unraid server addy)

rather than Host = localhost (or 127.0.0.1)

 

Is there a way to have Docker see all of the containers as being on the same host?  I am going to guess it has something to do with IP scheme (NAT vs. bridge vs. whatever) but I just don't know enough about that stuff.

 

After saying all of that, is there really any benefit?  I guess I see the fact that I have to specify the unraid server addy sends the traffic between containers in and out of the network.

 

John

 

EDIT:  Forgot to mention that my data mount point is consistent across all of my containers:  /mnt/ --> /mnt/

 

I have all mine communicating via "localhost:port" and also running on "host" network config.

 

Works fine.

 

Hmmm...I do have most of my containers set to Bridge for network type.  If I set to Host, do you lose the ability to remap the ports to avoid conflicts?

Link to comment

I'm not sure if I could be doing things better but...

 

Each of my containers that interacts with another container (i.e. Sonarr + SAB), I have to connect via IP rather than localhost.

 

For example, in Sonarr Settings --> Download Client --> SabNZBd

 

I have to set Host = 192.168.1.10 (my unraid server addy)

rather than Host = localhost (or 127.0.0.1)

 

Is there a way to have Docker see all of the containers as being on the same host?  I am going to guess it has something to do with IP scheme (NAT vs. bridge vs. whatever) but I just don't know enough about that stuff.

 

After saying all of that, is there really any benefit?  I guess I see the fact that I have to specify the unraid server addy sends the traffic between containers in and out of the network.

 

John

 

EDIT:  Forgot to mention that my data mount point is consistent across all of my containers:  /mnt/ --> /mnt/

 

I have all mine communicating via "localhost:port" and also running on "host" network config.

 

Works fine.

 

Hmmm...I do have most of my containers set to Bridge for network type.  If I set to Host, do you lose the ability to remap the ports to avoid conflicts?

 

Well, I guess the answer to that is Yes. Unless the internal config of the container allows you to change the port and then when you update it doesn't get overwritten.

 

I found though that I didn't really need to worry about conflicts. The only ones I have had to set to Host are KODI-Headless (normally 8080), Guacamole (normally 8080) and ReverseProxy (non SSL http port 80 - which Unraid runs on).

 

I left all the others - and it appears we have very similar setups.

Link to comment

how hard is it to type the ip rather than localhost ?

 

My point was that if both containers use localhost, aren't the transactions staying local rather than traversing the network?  Or, does docker recognize the unraid server IP as a local address?

Link to comment

how hard is it to type the ip rather than localhost ?

 

My point was that if both containers use localhost, aren't the transactions staying local rather than traversing the network?  Or, does docker recognize the unraid server IP as a local address?

 

if the containers use bridge, the transactions aren't traversing the network, they're traversing the bridge.

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...