Skip to content

docker 27.0.0~rc.1 does not use host dns #48015

@trivialkettle

Description

@trivialkettle

Description

On debian arm64 the new docker-ce version 27 rc1 is already published, after an update my buildx node on this host could not build a docker image that pull from an internal git server.

on arm64:

#13 [linux/arm64 build 4/5] RUN nslookup <my-url>
#13 0.264 Server:		8.8.8.8
#13 0.264 Address:	8.8.8.8#53
#13 0.264 
#13 0.264 Non-authoritative answer:
#13 0.264 Name:	<my_url>
#13 0.264 Address: <some ip>
#13 0.264 

on amd64 node:

#15 [linux/amd64 build 4/5] RUN nslookup <my-url>
#15 0.468 Server:		<internal dns server>
#15 0.468 Address:	<internal dns server>#53
#15 0.468 
#15 0.468 Name:	<my-url>
#15 0.468 Address: <my-ip>
#15 0.468 

I compared /etc/resolv.conf of the buildkit container:
arm64 on v27:

cat /etc/resolv.conf 
# Generated by Docker Engine.
# This file can be edited; Docker Engine will not make further changes once it
# has been modified.

nameserver 127.0.0.11
options ndots:0

# Based on host file: '/etc/resolv.conf' (internal resolver)
# ExtServers: <some ip>
# Overrides: []
# Option ndots from: internal 

arm64 on v26

/ # cat /etc/resolv.conf 
# Generated by Docker Engine.
# This file can be edited; Docker Engine will not make further changes once it
# has been modified.

nameserver <some ip>

# Based on host file: '/etc/resolv.conf' (legacy)
# Overrides: []

amd64 on v26

cat /etc/resolv.conf 
# Generated by Docker Engine.
# This file can be edited; Docker Engine will not make further changes once it
# has been modified.

nameserver <my dns server>
search <my dns search>

# Based on host file: '/etc/resolv.conf' (legacy)
# Overrides: []

I noticed on arm64 that the nameserver on v26 was moved to the line # ExtServers: [<ip>] on v27.
I could also manage to build successfully using docker buildx build --network=host

I know that v27 is not yet released, but maybe someone else runs into this too. Also how can I migrate to v27 and have workin DNS?

Reproduce

  1. update docker to version 27.0.0-rc1
  2. try nslookup for some internal dns name

Expected behavior

The correct IP should be resolved

docker version

docker --version
Docker version 27.0.0-rc.1, build 9dabf16

docker info

unfortunately I already downgraded and can not break the system to check `docker info`

Additional Info

No response

Metadata

Metadata

Assignees

Labels

area/networkingNetworkingarea/networking/dnsNetworkingkind/bugBugs are bugs. The cause may or may not be known at triage time so debugging may be needed.

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions