# Error: Discourse + NGINX as reverse proxy + Docker =\> TOO\_MANY\_REDIRECTS

**URL:** <https://meta.discourse.org/t/error-discourse-nginx-as-reverse-proxy-docker-too-many-redirects/176940>\
**Category:** Self-hosting\
**Created:** [January 22, 2021, 1:12pm UTC](https://meta.discourse.org/t/error-discourse-nginx-as-reverse-proxy-docker-too-many-redirects/176940 "2021-01-22T13:12:06Z")\
**Posts on this page:** 1\
**Page:** 1

## AI-generated summary

[Ingo_Karstein](/t/-/176940/1) reports encountering a "TOO_MANY_REDIRECTS" error after migrating a Docker-based Discourse server to a new host. The migration involved stopping the service on the old server, syncing files, and attempting to set up the new server using the existing `app.yml` file and `./discourse-setup`. The user employs NGINX as a reverse proxy with SSL termination, where Discourse itself is not configured for SSL and exposes port 80. Despite copying the NGINX configuration from the working old server and attempting a clean setup with an empty volume, the redirect loop persists. The issue did not exist on the previous server, suggesting a configuration discrepancy or environment difference introduced during the move.

<div class="post-metadata">

**Author:** ![Ingo\_Karstein](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ingo_karstein/32/206923_2.png) [@Ingo\_Karstein](https://meta.discourse.org/u/Ingo_Karstein)\
**Post date:** [January 22, 2021, 1:12pm UTC](https://meta.discourse.org/t/error-discourse-nginx-as-reverse-proxy-docker-too-many-redirects/176940/1 "2021-01-22T13:12:06Z")

</div>

Hi all,

I need to move my Docker based Discourse server from one host to another. There is a guide that I followed. No problem there.

I stopped Discourse on the old server, synced the files to the new server and tried to setup the new server using the existing “app.yml” file with “./discourse-setup”. I also tried “./launcher rebuild app”. There are no errors.

I use NGINX as reverse proxy with SSL (incoming). Discourse is connected by NGINX _not_ using SSL. The published port of the Discourse container is 80.

In NGINX a host name is registered with SSL and port 443 for Discourse with Redirection.

When I access the Discourse platform through a browser I get “TOO\_MANY\_REDIRECTS”.

That’s it. - This problem did not exist on the old server. I copied the Discourse and NGINX config from there.

I also tried to do a clean setup with “./docker-setup” and empty host volume. But with the same result: TOO\_MANY\_REDIRECTS.

Any ideas?

Regards  
Ingo
