Skip to content

Grabs current IPs used by docker containers and adds them to /etc/hosts

Notifications You must be signed in to change notification settings

onetrueandrew/docker_container_IPs_to_etchosts

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 

Repository files navigation

docker_container_IPs_to_etchosts

Grabs current IPs used by docker containers and adds them to /etc/hosts Useful for local hostname resolution, or for things like pi-hole that will attribute events to a container

Use:

$ ./add_names.sh /etc/hosts

Might need to run as root, depending on your docker setup...

# ./add_names.sh /etc/hosts

About

Grabs current IPs used by docker containers and adds them to /etc/hosts

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages