# Failed to install

**URL:** https://meta.discourse.org/t/failed-to-install/273479
**Category:** Self-hosting
**Created:** [August 1, 2023, 12:32pm UTC](https://meta.discourse.org/t/failed-to-install/273479 "2023-08-01T12:32:18Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![Deveroonie](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/deveroonie/32/291873_2.png) [@Deveroonie](https://meta.discourse.org/u/Deveroonie)
#### Post date: [August 1, 2023, 12:32pm UTC](https://meta.discourse.org/t/failed-to-install/273479/1 "2023-08-01T12:32:18Z")

</div>

I’m trying to install Discourse but am getting this

```plaintext
2023-08-01 12:27:18.881 UTC [42] LOG: database system is shut down

FAILED
--------------------
Pups::ExecError: cd /var/www/discourse && sudo -H -E -u discourse bash -c '
  set -o errexit
  if [$(git rev-parse --is-shallow-repository) == "true"]; then
      git remote set-branches --add origin main
      git remote set-branches origin tests-passed
      git fetch --depth 1 origin tests-passed
  else
      git fetch --tags --prune-tags --prune --force origin
  fi
' failed with return #<Process::Status: pid 147 exit 128>
Location of failure: /usr/local/lib/ruby/gems/3.2.0/gems/pups-1.1.1/lib/pups/exec_command.rb:117:in `spawn'
exec failed with the params {"cd"=>"$home", "hook"=>"code", "cmd"=>["sudo -H -E -u discourse git reset --hard", "sudo -H -E -u discourse git clean -f", "sudo -H -E -u discourse bash -c '\n set -o errexit\n if [$(git rev-parse --is-shallow-repository) == \"true\"]; then\n git remote set-branches --add origin main\n git remote set-branches origin $version\n git fetch --depth 1 origin $version\n else\n git fetch --tags --prune-tags --prune --force origin\n fi\n'", "sudo -H -E -u discourse bash -c '\n set -o errexit\n if [[$(git symbolic-ref --short HEAD) == $version]] ; then\n git pull\n else\n git -c advice.detachedHead=false checkout $version\n fi\n'", "sudo -H -E -u discourse git config user.discourse-version $version", "mkdir -p tmp", "chown discourse:www-data tmp", "mkdir -p tmp/pids", "mkdir -p tmp/sockets", "touch tmp/.gitkeep", "mkdir -p /shared/log/rails", "bash -c \"touch -a /shared/log/rails/{production,production_errors,unicorn.stdout,unicorn.stderr,sidekiq}.log\"", "bash -c \"ln -s /shared/log/rails/{production,production_errors,unicorn.stdout,unicorn.stderr,sidekiq}.log $home/log\"", "bash -c \"mkdir -p /shared/{uploads,backups}\"", "bash -c \"ln -s /shared/{uploads,backups} $home/public\"", "bash -c \"mkdir -p /shared/tmp/{backups,restores}\"", "bash -c \"ln -s /shared/tmp/{backups,restores} $home/tmp\"", "chown -R discourse:www-data /shared/log/rails /shared/uploads /shared/backups /shared/tmp", "[! -d public/plugins] || find public/plugins/ -maxdepth 1 -xtype l -delete"]}
bootstrap failed with exit code 128
**FAILED TO BOOTSTRAP** please scroll up and look for earlier error messages, there may be more than one.
./discourse-doctor may help diagnose the problem.
2b0150a1aac20c041b7de6173429a0a0b0133f8a63b5172a0e63f4d2ca5f22b0
==================== END REBUILD LOG ====================
Failed to rebuild app.

```

---

<div class="post-metadata">

### Author: ![Falco](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/falco/32/179432_2.png) [@Falco](https://meta.discourse.org/u/Falco)
#### Post date: [August 1, 2023, 1:16pm UTC](https://meta.discourse.org/t/failed-to-install/273479/2 "2023-08-01T13:16:17Z")

</div>

Can you post the whole log please?

---

<div class="post-metadata">

### Author: ![Deveroonie](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/deveroonie/32/291873_2.png) [@Deveroonie](https://meta.discourse.org/u/Deveroonie)
#### Post date: [August 1, 2023, 1:31pm UTC](https://meta.discourse.org/t/failed-to-install/273479/3 "2023-08-01T13:31:17Z")

</div>

sure! [EUR1Okdcax | SourceBin](https://srcb.in/EUR1Okdcax)

---

<div class="post-metadata">

### Author: ![Falco](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/falco/32/179432_2.png) [@Falco](https://meta.discourse.org/u/Falco)
#### Post date: [August 1, 2023, 2:05pm UTC](https://meta.discourse.org/t/failed-to-install/273479/4 "2023-08-01T14:05:44Z")

</div>

Error is

```plaintext
fatal: unable to access 'https://github.com/discourse/discourse.git/': Could not resolve host: github.com

```

Your host or containers have internet connectivity problems.

---

<div class="post-metadata">

### Author: ![Deveroonie](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/deveroonie/32/291873_2.png) [@Deveroonie](https://meta.discourse.org/u/Deveroonie)
#### Post date: [August 1, 2023, 3:07pm UTC](https://meta.discourse.org/t/failed-to-install/273479/5 "2023-08-01T15:07:57Z")

</div>

i managed to git clone it fine tho…

---

<div class="post-metadata">

### Author: ![Ed\_S](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ed_s/32/134015_2.png) [@Ed\_S](https://meta.discourse.org/u/Ed_S)
#### Post date: [August 3, 2023, 12:37pm UTC](https://meta.discourse.org/t/failed-to-install/273479/6 "2023-08-03T12:37:22Z")

</div>

The `git clone` action is taken in the host, so that shows the host is OK, but the subsequent actions take place in the container. If they fail, it indicates trouble within the container (docker) and in this case, DNS (name resolution) trouble.

There have been situations before where people report this kind of connectivity problem inside docker. Perhaps [see](https://meta.discourse.org/t/issue-when-installing-new-discourse-instance/259617/7)

> [@Issue when installing new Discourse instance](https://meta.discourse.org/t/issue-when-installing-new-discourse-instance/259617/7):
>
> try lowering the MTU of the Docker interface

It might be useful to have details of your provider and the location. It might be useful to test inside the container using commands something like this:

```plaintext
./launcher enter app 
ping -c2 github.com
exit

```
