Docker obtains the IP address of the host Author: Chuwen Time: 2021-09-12 Classification: Docker I didn't find anything related online This domain name gets the IP of the host: ` host. docker. internal` So you should know how to use it ``` [ root@3905274ca2a3 /]# ping host.docker.internal PING host.docker.internal (192.168.65.2) 56(84) bytes of data. 64 bytes from 192.168.65.2 (192.168.65.2): icmp_seq=1 ttl=37 time=0.173 ms 64 bytes from 192.168.65.2 (192.168.65.2): icmp_seq=2 ttl=37 time=0.524 ms 64 bytes from 192.168.65.2 (192.168.65.2): icmp_seq=3 ttl=37 time=0.248 ms 64 bytes from 192.168.65.2 (192.168.65.2): icmp_seq=4 ttl=37 time=0.515 ms ^C --- host.docker.internal ping statistics --- 4 packets transmitted, 4 received, 0% packet loss, time 3039ms rtt min/avg/max/mdev = 0.173/0.365/0.524/0.156 ms ``` label: Docker