Last active
February 3, 2021 17:19
-
-
Save adamancini/bcdfe4837b133ce1ea4fe027596bed31 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
✔ jane ~ docker run --rm -d --network project_foo --name svc1 nginx | |
8b04f5fe4265b16f985d5b9a6e0c25ebbc871f657d635b5cf5b93cd6a71d2f5e | |
✔ jane ~ docker run --rm -d --network project_foo --name svc2 nginx | |
1650e43bbe8b548d2e5f9614c90152858c32953ffbb4c5cdaa48bd8aceba4ee1 | |
↵ 126 jane ~ docker run --rm --network project_foo nicolaka/netshoot dig svc1 | |
; <<>> DiG 9.14.8 <<>> svc1 | |
;; global options: +cmd | |
;; Got answer: | |
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 17755 | |
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0 | |
;; QUESTION SECTION: | |
;svc1. IN A | |
;; ANSWER SECTION: | |
svc1. 600 IN A 172.20.0.2 | |
;; Query time: 0 msec | |
;; SERVER: 127.0.0.11#53(127.0.0.11) | |
;; WHEN: Wed Feb 03 17:17:30 UTC 2021 | |
;; MSG SIZE rcvd: 42 | |
✔ jane ~ docker run --rm --network project_foo nicolaka/netshoot dig +short svc1 | |
172.20.0.2 | |
✔ jane ~ docker network disconnect project_foo svc2 | |
✔ jane ~ docker run --rm --network project_foo nicolaka/netshoot dig +short svc2 | |
✔ jane ~ docker run --rm --network project_foo nicolaka/netshoot dig +short svc1 | |
172.20.0.2 | |
✔ jane ~ docker network connect project_foo svc2 | |
✔ jane ~ docker run --rm --network project_foo nicolaka/netshoot dig +short svc2 | |
172.20.0.3 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment