Too many redirect error after installing mattermost

If you’re looking for help, please provide information about your environment. If you delete this template and don’t provide any information, your topic will be closed.

If you aren’t running the latest version of Ghost, the first thing we will ask you to do is update to the latest version of Ghost.


  • How was Ghost installed and configured?
    on the command line following the ubuntu 18.04 installation guide

  • What Node version, database, OS & browser are you using?
    Node: latest, Database: mysql, OS: Ubuntu 18.04, Browser: Opera GX but also tested on chrome

  • What errors or information do you see in the console?

Aug 31 18:20:00 node[69507]:     at Object.getThemeValidationError (/var/www/****/versions/4.11.0/core/server/services/themes/val
Aug 31 18:20:00 node[69507]:     at Object.module.exports.loadAndActivate (/var/www/****/versions/4.11.0/core/server/services/the
Aug 31 18:20:00 node[69507]:     at async initFrontend (/var/www/****/versions/4.11.0/core/boot.js:122:5)
Aug 31 18:20:00 node[69507]:     at async bootGhost (/var/www/****/versions/4.11.0/core/boot.js:329:9)
Aug 31 18:20:00 node[69507]:
Aug 31 18:20:01 node[69507]: [2021-08-31 18:20:01] INFO Ghost booted in 3.806s
Aug 31 18:20:01 node[69507]: [2021-08-31 18:20:01] INFO Adding offloaded job to the queue
Aug 31 18:20:01 node[69507]: [2021-08-31 18:20:01] INFO Scheduling job update-check at 5 30 2 * * *. Next run on: Wed Sep 01 2021
Aug 31 18:20:01 node[69507]: [2021-08-31 18:20:01] INFO Bootstrap client was closed.
  • What steps could someone else take to reproduce the issue you’re having?
    Not really sure. It was working perfectly fine until I installed mattermost on the server on a different domain, then it was saying there was an SSL error, I reinstalled the certificates using certbot andthat fixed that, but now there’s an issue that it’s saying TOO MANY REDIRECTS and systemctl says it’s a ThemeValidationError

Update: After digging and using ghost run, I have discovered a possible source of the problem. I had included handlebars-helpers before to add the startsWith helper in 3 theme files, and it was working perfectly filtering team members. However for some reason it’s now throwing this error and I’m not actually sure why. Ghost hasn’t updated, the handlebars-helpers package still exists, the include in engine.js hasn’t been altered in any way, and there’s no reason why it should be working fine one moment and then throwing errors the next.

Update: After temporarily disabling the 3 custom theme files, the ThemeValidationError has gone, but the Too Many Redirects error still exists and this time Ghost is running without error

Update: had a look in the nginx error file and found this, leading me to believe that the previous certificate issue possibly caused by mattermost hasn’t been resolved
no resolver defined to resolve while requesting certificate status, responder:, certificate: "/etc/letsencrypt/live/"

Update: I deleted my nginx .conf files for the host domain so I could reinitialise and run ghost setup nginx ssl in an effort to try and fix this, and it did absolutely nothing. Out of curiosity I decided to run curl and it returns this:

<head><title>301 Moved Permanently</title></head>
<center><h1>301 Moved Permanently</h1></center>

and it returns the same for curl and curl