1. 程式人生 > >docker busybox服務中nslookup命令報錯

docker busybox服務中nslookup命令報錯

Server:         127.0.0.11
Address:        127.0.0.11:53

Non-authoritative answer:

*** Can't find tasks.busybox2: No answer

原因:新版busybox映象的問題,使用舊版本即可,如1.28.3版

docker service create --name busybox1 --network test busybox:1.28.3 sleep 100000000

docker exec -it busybox1.1.hv79nsq0vw4b20dy17oed7gil nslookup tasks.busybox2