# ./discourse-setup: could not resolve host: github.com

**URL:** https://meta.discourse.org/t/discourse-setup-could-not-resolve-host-github-com/172299
**Category:** Support
**Created:** [December 4, 2020, 11:48pm UTC](https://meta.discourse.org/t/discourse-setup-could-not-resolve-host-github-com/172299 "2020-12-04T23:48:05Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![minipunch](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/minipunch/32/202088_2.png) [@minipunch](https://meta.discourse.org/u/minipunch)
#### Post date: [December 4, 2020, 11:48pm UTC](https://meta.discourse.org/t/discourse-setup-could-not-resolve-host-github-com/172299/1 "2020-12-04T23:48:05Z")

</div>

When running `./discourse-setup` it continues to fail with the error:

```plaintext
cd /pups && git pull && /pups/bin/pups --stdin
fatal: unable to access 'https://github.com/discourse/pups.git/': Could not resolve host: github.com
fe7a66f6321f948dd840124da1f0165db18807367b4419e1cc9906eb7f71a0a8
**FAILED TO BOOTSTRAP**

```

I have tried like _at least_ 3 different solutions to this problem that I could find from this forum and around GitHub, including some Docker stack overflow answers for “lack of internet” and “DNS problems” within docker.

I have tried following like _at least_ 2 different tutorials I could find for setting the Discourse forum software up, the official one and some other one.

Things like setting up a `daemon.json` file with DNS’ configured. Setting the docker0 interface into promiscuous mode.

After all that I still get the same problem.

I am using an Ubuntu 20.04 server hosted by OVH.

I am able to ping [github.com](http://github.com) and get a response on the host, just not within the Docker setup.

Anyone able to help?

Edit: after hacking together a manual entry in the`/etc/hosts` file of the container environment for github’s IP address, it now says “connection timed out” instead of “unable to resolve [github.com](http://github.com)”.

---

<div class="post-metadata">

### Author: ![supermathie](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/supermathie/32/507518_2.png) [@supermathie](https://meta.discourse.org/u/supermathie)
#### Post date: [December 5, 2020, 1:29am UTC](https://meta.discourse.org/t/discourse-setup-could-not-resolve-host-github-com/172299/2 "2020-12-05T01:29:47Z")

</div>

This is at least the second report in recent days.

> [@After upgrade, docker cannot communicate with the outside world](https://meta.discourse.org/t/after-upgrade-docker-cannot-communicate-with-the-outside-world/171902/20):
>
> Honestly, I think the best approach at this point is to reinstall and copy your data over. You have a broken system for Mysterious Reasons, and the installation process is rather quick. It’s likely the best use of your time.

We’ll take a look at the process.

---

<div class="post-metadata">

### Author: ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)
#### Post date: [December 5, 2020, 2:44am UTC](https://meta.discourse.org/t/discourse-setup-could-not-resolve-host-github-com/172299/3 "2020-12-05T02:44:44Z")

</div>

How’d you install docker?

---

<div class="post-metadata">

### Author: ![minipunch](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/minipunch/32/202088_2.png) [@minipunch](https://meta.discourse.org/u/minipunch)
#### Post date: [December 5, 2020, 4:14am UTC](https://meta.discourse.org/t/discourse-setup-could-not-resolve-host-github-com/172299/4 "2020-12-05T04:14:44Z")

</div>

> [@pfaffman](#):
>
> How’d you install docker?

I think the first time I ran `/discourse-setup` it installed Docker for me.

And after hacking together a manual entry in the`/etc/hosts` file of the container environment for github’s IP address, it now says “connection timed out” instead of “unable to resolve [github.com](http://github.com)”.

So it seems like it might be an internet connection problem in general and not just a DNS thing. I even tried running it with the `--network host` option and it still didn’t work even though it does work on my host.

If I run a simple test Docker container, I am able to reach the internet from it. It just seems like the Discourse container is not connecting out.

---

<div class="post-metadata">

### Author: ![minipunch](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/minipunch/32/202088_2.png) [@minipunch](https://meta.discourse.org/u/minipunch)
#### Post date: [December 8, 2020, 5:15pm UTC](https://meta.discourse.org/t/discourse-setup-could-not-resolve-host-github-com/172299/5 "2020-12-08T17:15:15Z")

</div>

Just as a note, it seems to be working fine on a DigitalOcean droplet (as recommended by the README). However this problem still persists on my existing Ubuntu 20.04 server.

---

<div class="post-metadata">

### Author: ![niels-anders](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/niels-anders/32/204861_2.png) [@niels-anders](https://meta.discourse.org/u/niels-anders)
#### Post date: [January 3, 2021, 12:39pm UTC](https://meta.discourse.org/t/discourse-setup-could-not-resolve-host-github-com/172299/6 "2021-01-03T12:39:56Z")

</div>

I am having the same issue with a default digital ocean droplet based on ubuntu 20.04. Did you find a solution yet?

seems to work now, see [After upgrade, docker cannot communicate with the outside world - #24 by niels-anders](https://meta.discourse.org/t/after-upgrade-docker-cannot-communicate-with-the-outside-world/171902/24)
