Err too many redirects

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • tempus
    Junior Member
    • Apr 2017
    • 8

    Err too many redirects

    Please help to set up ESPOCRM dockerised instance behind the nginx proxy.

    After executing original docker compose yml https://hub.docker.com/r/espocrm/espocrm I can access ESPOCRM from internal network, but from outside it throws ERR_TOO_MANY_REDIRECTS

    I am using nginx to proxy requests. Nginx conf goes here:

    server {
    server_name mydomain.com;
    listen 443 ssl; # managed by Certbot
    ssl_certificate /etc/letsencrypt/live/mydomain.com/fullchain.pem; # managed by Certbot
    ssl_certificate_key /etc/letsencrypt/live/mydomain.com/privkey.pem; # managed by Certbot
    include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
    ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
    access_log /var/log/nginx/mydomain.com.access.log;

    location / {

    # Set the proxy headers

    proxy_set_header Host $host;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header X-Forwarded-Proto $scheme;

    # Configure which address the request is proxied to

    proxy_pass http://server_ip_address:8080/;
    proxy_read_timeout 90;
    }

    }

    server {
    if ($host = mydomain.com) {
    return 301 https://$host$request_uri;
    } # managed by Certbot

    listen 80;
    server_name mydomain.com;
    return 404; # managed by Certbot


    }​
  • tempus
    Junior Member
    • Apr 2017
    • 8

    #2
    The SSL configuration did the trick. Admins, please delete this thread!

    Thank you

    Comment

    Working...