#resolv.conf

1 messages · Page 1 of 1 (latest)

calm canyon
#

The resolv.conf generated for the dagger engine is not the same as a resolv.conf file generated by doing a docker run .

Docker run produces this:

docker run node:16-slim cat /etc/resolv.conf

search dun.fh home
nameserver 10.11.1.14
nameserver 10.11.1.15
nameserver 192.168.1.1

However, the dagger engine container loses the .dun.fh domain and just leaves the last known entry:

search home
nameserver 10.11.1.14
nameserver 10.11.1.15
nameserver 192.168.1.1
    const image = client.directory().withNewFile(
        'Dockerfile',
        `
            FROM node:16-slim 
        `
    );

    await client
        .container()
        .build(image)
        .withEnvVariable('BUST_CACHE', Math.random().toString())
        .withExec(['cat', '/etc/resolv.conf'])
        .stdout();

It's not a big deal as I tend to use the fqdn in all of my commands that talk over the internet, but I'm curious as to why there's a difference?

Node SDK: 0.30

Haven't tested this with other SDKS.