Hi, I’m very new to Docker so please be gentle.
I recently put a Discourse instance on my server with Docker. I am using HAProxy to divert the Discourse domain to the Docker container, and everything else as normal to Apache.
Docker was having issues connecting to the internet though, and this thread suggests uncommenting this line:
DOCKER_OPTS="--dns 8.8.8.8 --dns 8.8.4.4"
in /etc/default/docker
a file that doesn’t exist on my CentOS 6.5 install. But this one does /etc/sysconfig/docker
so I add the line to the bottom of this file, restart Docker with service docker restart
and it worked!
But then at some point (since yesterday) it just stopped working, and restarting docker again gets it working.
I’m worried there’s some reason why this isn’t sticking, does anyone know what the correct configuration should be?
My /etc/sysconfig/docker
now reads like the below - I moved the Docker_opts line just below the cert_path (it was originally at the bottom of the file)
#
# Other arguments to pass to the docker daemon process
# These will be parsed by the sysv initscript and appended
# to the arguments list passed to docker -d
other_args=
DOCKER_CERT_PATH=/etc/docker
DOCKER_OPTS="--dns 8.8.8.8 --dns 8.8.4.4"
# Location used for temporary files, such as those created by
# # docker load and build operations. Default is /var/lib/docker/tmp
# # Can be overriden by setting the following environment variable.
# # DOCKER_TMPDIR=/var/tmp
Any ideas what’s going on or how I can sort this out please?