Nginx Ssl and Auth0 goes into login loop

Hi, I am sorry If this is the wrong section, I am using ubuntu vps, installed ssl certificate and what I am trying to achieve is to nginx to redirect all http traffic to https, but having problem at Auth0 login.

My nginx config is as follows:

server {
listen 80;
server_name admin.example.com;
return 301 https://admin.example.com$request_uri;
}

server {
listen 443 ssl;
ssl on;

ssl_certificate /etc/letsencrypt/live/admin.example.com/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/admin.example.com/privkey.pem;
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot

location / {
    proxy_pass http://localhost:5000;
    proxy_http_version 1.1;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection keep-alive;
    proxy_set_header Host $http_host;
    proxy_cache_bypass $http_upgrade;
}

}

now if I add the following address to allowed callback urls in my application page

/signin-auth0 it gives error as
/signin-auth0 is not found in allowed callback urls.

if I add /signin-auth0,
/signin-auth0 or both http and https it goes to a loop as I login, it directs me to login page again infinitely.

forum says I can only use 3 links in a post so I use placeholders, sorry for inconvenience.

http://admin.example.com
https://admin.example.com

sorry I cannot edit or delete post above so the correct on if the one below

Hi, I am sorry If this is the wrong section, I am using ubuntu vps, installed ssl certificate and what I am trying to achieve is to nginx to redirect all http traffic to https, but having problem at Auth0 login.

My nginx config is as follows:

server {
listen 80;
server_name http://admin.example.com;
return 301 https://admin.example.com$request_uri;
}

server {
listen 443 ssl;
ssl on;

ssl_certificate /etc/letsencrypt/live/admin.example.com/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/admin.example.com/privkey.pem;
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot

location / {
    proxy_pass http://localhost:5000;
    proxy_http_version 1.1;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection keep-alive;
    proxy_set_header Host $http_host;
    proxy_cache_bypass $http_upgrade;
}






}

now if I add the following address to allowed callback urls in my application page

https://admin.example.com/signin-auth0 it gives error as
http://admin.example.com/signin-auth0 is not found in allowed callback urls.

if I add http://admin.example.com/signin-auth0 or
both http and https addresses it goes to a loop as I login, it directs me to login page again infinitely.

Hey there!

Terribly sorry for such delay in response! We’re doing our best in providing the best developer support experience out there, but sometimes our bandwidth is just not enough for all the questions that are coming in. Sorry for the inconvenience!

Do you still require further assistance from us?