Users are encountering a ‘Failed to Bootstrap’ error during Discourse Docker setup, specifically failing to resolve GitHub while pulling the pups repository, despite successful ping and wget tests to GitHub. kushanx reports the issue on a Singapore-based DigitalOcean droplet. Suggestions include checking for regional GitHub blocks DeanMarkTaylor, but the root cause appears to be DNS resolution within Docker containers. Stefan and neounix recommend editing /etc/default/docker to set Google DNS (8.8.8.8 and 8.8.4.4) and restarting Docker, which resolves the issue for many. danlucraft finds that --iptables=false in DOCKER_OPTS breaks DNS resolution and causes Bad Gateway errors, even though it previously worked; removing it restores functionality. xiasummer suggests rebooting as a workaround. minipunch reports the DNS fix didn’t work on Ubuntu 20.04, indicating potential OS-specific or configuration-related persistence of the issue. The consensus is that Docker’s internal DNS configuration is the culprit, and overriding it with public DNS servers typically resolves the bootstrap failure.
Thanks for the tips. I’ll check them asap. I’m not in or from India. I
use git daily for learning purposes. And the digital ocean droplet is
located in Singapore.
I CAN PROVIDE access to it. Made a mistake in the first post.
fatal: unable to access 'https://github.com/SamSaffron/pups.git/': Could not resolve host: github.com"_ during `./launcher rebuild app`.
My installation was all working fine for a week beforehand but today it told me Sidekiq wasn’t running so I went to rebuild, which has now failed.
I can ping github outside the container and the wget test above also works fine. I’ve tried with and without the DNS options in /etc/default/docker (and restarted the docker service after editing each time).
If it matters, I have added --iptables=false to the DOCKER_OPTS variable, as I wanted to restrict access to the Discourse install by IP with ufw. I am not blocking outgoing traffic at all (and as I said pinging github works anyway).
Any more ideas?
EDIT: there are no other error messages. Also “Fetching origin” seems to complete without errors (and the first time it actually pulled so commits) so I’m very confused as to why only on the pups repo it can’t resolve Github.
So I need to disable that to rebuild and then reenable it afterwards. Or will it cause problems if I leave the option in while the container is running?
It no longer works at all with the --iptables=false option. Now the site returns a Bad Gateway when that option is present. That’s weird because it worked fine with it with for over a week before.
Any advice on how to restrict access to port 80 by IP? I was using ufw to set the policy but Docker seems to completely bypass that using iptables directly.