Docker daemon config file on boot2docker / docker-machine / Docker Toolbox

0 votes
Where can I find docker daemon config file on boot2docker machine?

I need to set '--dns' in DOCKER_OPTS, but I can't find this config file either at /etc/default or anywhere else.
Jul 31, 2018 in Docker by Hannah
• 14,080 points
175 views

1 answer to this question.

0 votes

Inside boot2docker (boot2docker ssh) / docker-machine (docker-machine ssh default) , open or create the file /var/lib/boot2docker/profile and add the following line:

EXTRA_ARGS="--dns 192.168.1.145"

Also works for:

EXTRA_ARGS="--insecure-registry myinternaldocker"

After the change you need to restart the docker daemon:

sudo /etc/init.d/docker restart

Or leave boot2docker / docker-machine and restart the entire virtual machine:

boot2docker restart
# for docker machine
docker-machine restart default
answered Jul 31, 2018 by Kalgi
• 37,420 points

Related Questions In Docker

0 votes
1 answer

Different file owner inside Docker container and in host machine Ask

Filesystems, at least in Unix- and Linux-like ...READ MORE

answered Jun 25, 2018 in Docker by Damon Salvatore
• 5,490 points
60 views
0 votes
1 answer

Different file owner inside Docker container and in host machine

Here is what you can try. Since ...READ MORE

answered Jun 27, 2018 in Docker by Atul
• 10,240 points
122 views
+1 vote
5 answers

Where are Docker images stored on the host machine?

The contents of the /var/lib/docker directory vary ...READ MORE

answered Jul 18, 2018 in Docker by Kalgi
• 2,620 points
1,571 views
0 votes
1 answer
0 votes
1 answer

Deploy Docker Containers from Docker Cloud

To solve this problem, I followed advice ...READ MORE

answered Sep 3, 2018 in AWS by Priyaj
• 56,160 points
100 views
0 votes
1 answer

Docker Toolbox - hang on `docker push`

You can just run: docker-machine stop <name-of-your-docker-machine> which is ...READ MORE

answered Aug 2, 2018 in Docker by Kalgi
• 37,420 points
49 views
+4 votes
4 answers

How To Access a Service on Host From a Docker Container?

Adding to kalgi's answer, You can also ...READ MORE

answered Oct 16, 2018 in Docker by lina
• 8,100 points

edited Oct 16, 2018 by lina 3,260 views