Skip to content

fix(docs): fix dig commands for each CoreDNS instance in local tutorial #1832

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mattwelke
Copy link

@mattwelke mattwelke commented Feb 12, 2025

Resolves #1830.

Fixes the commands by removing "+tcp" from them, so that dig uses UDP instead.

Error before:

;; communications error to 127.0.0.1#5053: connection reset
;; communications error to 127.0.0.1#5053: connection reset
;; communications error to 127.0.0.1#5053: connection reset

; <<>> DiG 9.18.30-0ubuntu0.24.04.2-Ubuntu <<>> -p 5053 @localhost localtargets-roundrobin.cloud.example.com +tcp
; (1 server found)
;; global options: +cmd
;; no servers could be reached

Output after (example):

; <<>> DiG 9.18.30-0ubuntu0.24.04.2-Ubuntu <<>> -p 5053 @localhost localtargets-roundrobin.cloud.example.com
; (1 server found)
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 51033
;; flags: qr rd; QUERY: 1, ANSWER: 2, AUTHORITY: 0, ADDITIONAL: 1
;; WARNING: recursion requested but not available

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 1232
; COOKIE: 507a607e1c0ee13c (echoed)
;; QUESTION SECTION:
;localtargets-roundrobin.cloud.example.com. IN A

;; ANSWER SECTION:
localtargets-roundrobin.cloud.example.com. 30 IN A 172.19.0.4
localtargets-roundrobin.cloud.example.com. 30 IN A 172.19.0.5

;; Query time: 0 msec
;; SERVER: 127.0.0.1#5053(localhost) (UDP)
;; WHEN: Wed Feb 12 18:20:01 EST 2025
;; MSG SIZE  rcvd: 196


; <<>> DiG 9.18.30-0ubuntu0.24.04.2-Ubuntu <<>> -p 5054 @localhost localtargets-roundrobin.cloud.example.com
; (1 server found)
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 4687
;; flags: qr rd; QUERY: 1, ANSWER: 2, AUTHORITY: 0, ADDITIONAL: 1
;; WARNING: recursion requested but not available

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 1232
; COOKIE: 16704ecdcd80ad83 (echoed)
;; QUESTION SECTION:
;localtargets-roundrobin.cloud.example.com. IN A

;; ANSWER SECTION:
localtargets-roundrobin.cloud.example.com. 30 IN A 172.19.0.7
localtargets-roundrobin.cloud.example.com. 30 IN A 172.19.0.8

;; Query time: 0 msec
;; SERVER: 127.0.0.1#5054(localhost) (UDP)
;; WHEN: Wed Feb 12 18:20:02 EST 2025
;; MSG SIZE  rcvd: 196

Copy link

netlify bot commented Feb 12, 2025

Deploy Preview for k8gb-preview ready!

Name Link
🔨 Latest commit a9b59f0
🔍 Latest deploy log https://app.netlify.com/sites/k8gb-preview/deploys/67ad2d93c390b300083bf701
😎 Deploy Preview https://deploy-preview-1832--k8gb-preview.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@mattwelke mattwelke changed the title docs: fix dig commands for each CoreDNS instance in local tutorial fix(docs): fix dig commands for each CoreDNS instance in local tutorial Feb 12, 2025
Copy link
Collaborator

@k0da k0da left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@k0da
Copy link
Collaborator

k0da commented Feb 13, 2025

Although Colima on MacOS can't forward UDP traffic, so we setup TCP there

@mattwelke
Copy link
Author

Ah so it's a Mac vs. Linux thing. Do you know if there's a way to write a command that works on both?

@kuritka
Copy link
Collaborator

kuritka commented Feb 21, 2025

Hi @mattwelke , The long story short, the Docker Desktop has strict licensing requirements for using in corporations. It is not free, so instead of Docker Desktop, Colima was chosen. Unfortunately, Colima does not support UDP, so we explicitly use TCP for testing.

@kuritka
Copy link
Collaborator

kuritka commented Feb 27, 2025

@k0da , @jkremser , @ytsarev , @abaguas -
Hi, in this PR, I wanted to ask whether we still want to maintain the TCP protocol in the testing environment. From my perspective – the strict security restrictions limit me a lot, so I no longer use Colima and develop k8gb on my personal computer with Docker Desktop. For me, TCP is just another layer of complexity. What’s your opinion on this?

@ytsarev
Copy link
Member

ytsarev commented Feb 27, 2025

Should we hide tcp behind the configuration flag and switch to udp by default?

@abaguas
Copy link
Collaborator

abaguas commented Mar 8, 2025

I develop using Docker Desktop, so I am also fine switching to udp by default

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unable to connect to CoreDNS instances when running local tutorial
5 participants