i have a bit messed up Docker environment. Let me start from the beginning, i have a fresh installed Ubuntu 12.04 hardware box which were used dedicated to run GitLab.
Now since it has a quite decent CPU and tons of free RAM, i thought about installing Docker and setting up a Discourse forum as replacement for my current Vanilla forums. I started and just did a aptitude install docker.io
and pulled the latest available Docker package from the Ubuntu PPA.
Then i was looking at the Docker installation documentation and saw that they use a different way to install. I thought "okay, better use the same way to have the correct installation of Docker". So i just went with wget -qO- https://get.docker.io/ | sh
, but forgot to purge the old installation first.
However, i continued with the Discourse installation and had some issue regarding the auto start of the containers. Whenever the host system boots, the containers indeed start, but they have limited connectivity. For example: I cant rebuild the image because apparently it can't resolve github.com
:
root@host /var/discourse # ./launcher rebuild app
WARNING: No swap limit support
Updating discourse docker
Already up-to-date.
Stopping old container
4ddf909d349592ee9620d7bfc36b8c602f1e924cf3c179a81faa0be5e753a74d
Calculated ENV: -e LANG=en_US.UTF-8 -e RAILS_ENV=production -e UNICORN_WORKERS=6 -e UNICORN_SIDEKIQS=1 -e RUBY_GC_MALLOC_LIMIT=40000000 -e RUBY_HEAP_MIN_SLOTS=800000 -e DISCOURSE_DB_SOCKET=/var/run/postgresql -e DISCOURSE_DB_HOST= -e DISCOURSE_DB_PORT= -e HOME=/root -e DISCOURSE_DEVELOPER_EMAILS=mail@domain.com -e DISCOURSE_HOSTNAME=forums.domain.com -e DISCOURSE_SMTP_ADDRESS=smtp.mandrillapp.com -e DISCOURSE_SMTP_PORT=587 -e DISCOURSE_SMTP_USER_NAME=info@domain.com -e DISCOURSE_SMTP_PASSWORD=password
cd /pups && git pull && /pups/bin/pups --stdin
fatal: unable to access 'https://github.com/SamSaffron/pups.git/': Could not resolve host: github.com
d2510635bf60babe1dfa59d29a8ce78ec10477810e3c282b896101b34456003d
FAILED TO BOOTSTRAP
Another problem is that the container can't send mails via SMTP (mandrillapp.com). So i digged a bit, and somehow had the idea just to restart Docker with service docker restart
, and voilà: the issues are gone. DNS works as well as mails are going to sent successfully again.
So basically when the host reboots, i have to service docker restart
to make Docker work fully functional.
I already looked for some dead init scripts but there is only one:
root@host ~ # ls -alR /etc/init.d/ | grep docker
-rwxr-xr-x 1 root root 3421 Aug 21 21:24 docker
Can someone help me out here?