sync actions will replace previous content of the given profile.Sync with Docker
hostctl allows you synchronize your hosts file with docker containers a simple command.
sync actions will replace previous content of the given profile.Once you have some containers up and running, you can create names for all of them to their container IP.
Command:
hostctl sync docker awesome
Output:
+---------+--------+------------+------------------------+
| PROFILE | STATUS | IP | DOMAIN |
+---------+--------+------------+------------------------+
| awesome | on | 172.17.0.2 | mystifying_wescoff.loc |
| awesome | on | 172.17.0.2 | my-awesome-web.loc |
+---------+--------+------------+------------------------+
--name it will have a random container name.--domain,-d some.domain domain name used for all containers.
--network networkID|networkName filter only containers of an specific docker network.
Content