What's new
PGBlitz.com

Register Now! Find useful tips, Interact /w Community Members and join the part the Best Community on the Internet!

Discussion Fixed docker ip addresses?

macfreaker

Blitz Sergeant
I have already seen that sometimes after rebuilding the system (add remove containers or whatever) that the ip addresses of the docker containers where changed. And sometimes it happens when restarting the rebuilding and restarting the containers that the ip addresses are changed and then the apps don't talk to each other anymore (ex. Radarr with nzbget). I have seen in the docker documentation that it is possible to give a fixed ip to each container.
Maybe to keep a good running system after rebuilding this could be added to the scripts of the docker container.
Example:

Code:
version: '2'
services:
  nginx:
    image: nginx
    container_name: nginx-container
    networks:
      static-network:
        ipv4_address: 172.17.0.2
networks:
  static-network:
    ipam:
      config:
        - subnet: 172.17.0.0/16
 

Admin9705

Administrator
Project Manager
you never put by ip. you just put the ip port or you can type the name of the app and it will be good. it is, but you can attempt to fork and try it out the theory :D
 

macfreaker

Blitz Sergeant
I have tested this and this was working until there was an PlexGuide update. Then you have to start again because everything was overwritten. So I am using hostnames to mention a certain program/container when needed. You can still put fixed ip addresses under /opt/plexguide/programs/containers. Choose the containers where you want to add a fixed address and I think it was then where you fill in the ports to change in ipaddress:port you are using.
 

Admin9705

Administrator
Project Manager
I have tested this and this was working until there was an PlexGuide update. Then you have to start again because everything was overwritten. So I am using hostnames to mention a certain program/container when needed. You can still put fixed ip addresses under /opt/plexguide/programs/containers. Choose the containers where you want to add a fixed address and I think it was then where you fill in the ports to change in ipaddress:port you are using.
haha my bad on the update, but i hope you noticed the improvement in deployment :D
 

bringonblink

Blitz 3rd Class
Slightly off topic but i have a question about the docker ip addresses. Does it make a difference if i access a service (say tautulli) directly from my servers external ip address, or via the docker ip address over a vpn?
 

Create an account or login to comment

You must be a member in order to leave a comment

Create account

Create an account on our community. It's easy!

Log in

Already have an account? Log in here.

Similar threads


Development Donations

 

Top NZB NewsGroups!

Members - Up To a 58% Discount!

Trending

Top