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

Unable to add custom DNS to container using flannel plugin #128

Open
suryakantgarg opened this Issue Mar 9, 2018 · 2 comments

Comments

Projects
None yet
3 participants
@suryakantgarg
Copy link

suryakantgarg commented Mar 9, 2018

My /etc/cni/net.d/10-flannelnet.conf file looks like this :
{
"name": "flannelnet",
"type": "flannel",
"subnetFile": "/var/run/flannel/subnet.env",
"delegate":{ "isDefaultGateway": true},
"dns": {
"nameservers": [ "10.112.10.2" ]
}
}

I tried to create network endpoint using scripts avaliable at : https://github.com/containernetworking/cni/tree/master/scripts

Endpoint inside container gets created but there is no entry of dns server in /etc/resolv.conf inside container

@squeed

This comment has been minimized.

Copy link
Member

squeed commented Mar 13, 2018

The DNS field in CNI is currently unused by most runtimes, rkt being the only exception. So if you're using Kubernetes, for example, it won't work.

It should probably just be removed.

@rosenhouse

This comment has been minimized.

Copy link
Member

rosenhouse commented Mar 13, 2018

Cloud Foundry respects it too! :-)

But we're probably going to stop respecting it soon, I think.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment