# Error 500 after command line rebuild

**URL:** https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576
**Category:** Self-hosting
**Created:** [January 14, 2020, 5:13pm UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576 "2020-01-14T17:13:01Z")
**Posts on this page:** 16
**Page:** 1

<div class="post-metadata">

### Author: ![jdelmore](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jdelmore/32/120132_2.png) [@jdelmore](https://meta.discourse.org/u/jdelmore)
#### Post date: [January 14, 2020, 5:13pm UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576/1 "2020-01-14T17:13:01Z")

</div>

I am running Discourse in Docker using the official docker container  
[https://github.com/discourse/discourse\_docker](https://github.com/discourse/discourse_docker)

After issuing  
./launcher rebuild app

I am presented with

# Oops

The software powering this discussion forum encountered an unexpected problem. We apologize for the inconvenience.

Detailed information about the error was logged, and an automatic notification generated. We’ll take a look at it.

No further action is necessary. However, if the error condition persists, you can provide additional detail, including steps to reproduce the error, by posting a discussion topic in the site’s feedback category.

---

<div class="post-metadata">

### Author: ![jdelmore](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jdelmore/32/120132_2.png) [@jdelmore](https://meta.discourse.org/u/jdelmore)
#### Post date: [January 17, 2020, 4:05pm UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576/2 "2020-01-17T16:05:18Z")

</div>

Can anyone help me with this? I am getting this (see image below) warning, however I do not think it is the cause. I do not have any plug-ins enabled. i.e the git clone repos for them are commented out in the app.yml file.

 ![image](https://global.discourse-cdn.com/meta/original/3X/d/5/d59c6f433552f58ab4ea564d19184a7b2bd86931.png)

---

<div class="post-metadata">

### Author: ![itsbhanusharma](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/itsbhanusharma/32/180717_2.png) [@itsbhanusharma](https://meta.discourse.org/u/itsbhanusharma)
#### Post date: [January 17, 2020, 4:16pm UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576/3 "2020-01-17T16:16:17Z")

</div>

Try a `git pull` before rebuild

```plaintext
cd /var/discourse
git pull
./launcher rebuild app

```

---

<div class="post-metadata">

### Author: ![jdelmore](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jdelmore/32/120132_2.png) [@jdelmore](https://meta.discourse.org/u/jdelmore)
#### Post date: [January 17, 2020, 7:12pm UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576/4 "2020-01-17T19:12:10Z")

</div>

I have done a git pull however I am greeted with this issue.

 ![image](https://global.discourse-cdn.com/meta/original/3X/e/c/ec89156dab48bcf799080daf70614af275f96e03.png)

---

<div class="post-metadata">

### Author: ![jdelmore](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jdelmore/32/120132_2.png) [@jdelmore](https://meta.discourse.org/u/jdelmore)
#### Post date: [January 17, 2020, 7:15pm UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576/5 "2020-01-17T19:15:10Z")

</div>

is there anyway to recover the database and create a new instance of this?

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [January 17, 2020, 7:30pm UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576/6 "2020-01-17T19:30:30Z")

</div>

You need to provide the full build logs, your screenshot is a tiny fraction. Paste it into pastebin or similar and link it.

---

<div class="post-metadata">

### Author: ![itsbhanusharma](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/itsbhanusharma/32/180717_2.png) [@itsbhanusharma](https://meta.discourse.org/u/itsbhanusharma)
#### Post date: [January 17, 2020, 9:58pm UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576/7 "2020-01-17T21:58:17Z")

</div>

There isn’t any issue afaik. These look to me like fairly normal console logs that pop up around rebuild.

---

<div class="post-metadata">

### Author: ![michaeld](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/michaeld/32/1594_2.png) [@michaeld](https://meta.discourse.org/u/michaeld)
#### Post date: [January 17, 2020, 10:25pm UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576/8 "2020-01-17T22:25:13Z")

</div>

Agreed that the deprecation logs are normal, but it _is_ returning an error 500.

---

<div class="post-metadata">

### Author: ![Stephen](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/stephen/32/95011_2.png) [@Stephen](https://meta.discourse.org/u/Stephen)
#### Post date: [January 18, 2020, 1:24am UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576/9 "2020-01-18T01:24:41Z")

</div>

Which plugins are you using?

---

<div class="post-metadata">

### Author: ![jdelmore](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jdelmore/32/120132_2.png) [@jdelmore](https://meta.discourse.org/u/jdelmore)
#### Post date: [January 18, 2020, 5:07pm UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576/10 "2020-01-18T17:07:02Z")

</div>

The plugins that are enabled are listed below:  
docker\_manager  
babble  
discourse-chat-integration

At the moment the page simply does not load anything. it appears blank. /logs does load but no links work. /safe-mode loads but will not load after hitting the “Enter [Safe Mode](https://meta.discourse.org/t/53504?silent=true)” button.

Here is a pastebin of the output build.  
./launcher rebuild app \> ~/discourse\_build.log

[https://pastebin.com/7Za2D7NJ](https://pastebin.com/7Za2D7NJ)

---

<div class="post-metadata">

### Author: ![alextheblade](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/alextheblade/32/139788_2.png) [@alextheblade](https://meta.discourse.org/u/alextheblade)
#### Post date: [January 18, 2020, 5:11pm UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576/11 "2020-01-18T17:11:20Z")

</div>

Also can you try ./launcher enter app  
then do curl [http://localhost:3000](http://localhost:3000) and see what the output is

---

<div class="post-metadata">

### Author: ![jdelmore](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jdelmore/32/120132_2.png) [@jdelmore](https://meta.discourse.org/u/jdelmore)
#### Post date: [January 18, 2020, 5:19pm UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576/12 "2020-01-18T17:19:00Z")

</div>

The output from curl http:/localhost:3000  
[https://pastebin.com/wYaA3N5c](https://pastebin.com/wYaA3N5c)

---

<div class="post-metadata">

### Author: ![alextheblade](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/alextheblade/32/139788_2.png) [@alextheblade](https://meta.discourse.org/u/alextheblade)
#### Post date: [January 18, 2020, 5:21pm UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576/13 "2020-01-18T17:21:41Z")

</div>

Thanks, that didn’t help like I thought it would, sorry about that!

---

<div class="post-metadata">

### Author: ![alextheblade](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/alextheblade/32/139788_2.png) [@alextheblade](https://meta.discourse.org/u/alextheblade)
#### Post date: [January 18, 2020, 8:02pm UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576/15 "2020-01-18T20:02:31Z")

</div>

ok try this:  
I looked at your site headers with curl,

```
Content-Security-Policy: base-uri 'none'; object-src 'none'; 
script-src 'report-sample' http://mechassaultonline.com/logs/ 
http://mechassaultonline.com/sidekiq/ 
http://mechassaultonline.com/mini-profiler-resources/ 
http://mechassaultonline.com/assets/ 

```

etc etc. so first change your site name in containers/app.yml to [www.mechassaultonline.com](http://www.mechassaultonline.com) and rebuild, then check the force https checkbox at [https://www.mechassaultonline.com/admin/site\_settings/category/all\_results?filter=https](https://www.mechassaultonline.com/admin/site_settings/category/all_results?filter=https). That should do it!

---

<div class="post-metadata">

### Author: ![jdelmore](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jdelmore/32/120132_2.png) [@jdelmore](https://meta.discourse.org/u/jdelmore)
#### Post date: [January 19, 2020, 3:17am UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576/16 "2020-01-19T03:17:38Z")

</div>

combination of that. and this →

> [@Discourse refused to load with CSP policy error after rebuild](https://meta.discourse.org/t/discourse-refused-to-load-with-csp-policy-error-after-rebuild/117142/3):
>
> well I am upgrading after several days or maybe 2-3 months I do not even remember… However, I removed the images and installed from scratch but its still the same.

Looks like everything is up and running. thanks for all the help!

---

<div class="post-metadata">

### Author: ![JammyDodger](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jammydodger/32/254611_2.png) [@JammyDodger](https://meta.discourse.org/u/JammyDodger)
#### Post date: [November 28, 2023, 11:08pm UTC](https://meta.discourse.org/t/error-500-after-command-line-rebuild/138576/18 "2023-11-28T23:08:33Z")

</div>


