How to Remove Port: https://login.domain.com:8443/cas to https://login.domain.com

114 views
Skip to first unread message

Fahmi L. Ramdhani

unread,
Sep 25, 2018, 4:52:22 PM9/25/18
to CAS Community
Hello, how to remove ports (to 443) while i use NGINX too. I want to like https://login.domain.com/. Following cas configuration:

etc/cas/config/cas.properties:
cas.server.name: https://login.domain.com:8443
cas
.server.prefix: ${cas.server.name}/cas


nginx/sites-available/login.domain.com
server {
 listen
[::]:443 ssl ipv6only=on;
 listen
443 ssl;

 server_name login
.domain.com;
 root
/var/www/login.domain.com;

 charset utf
-8;

 location
/ {
    proxy_pass  
???????
 
}

 ssl_certificate
.............;
 ssl_certificate_key
................;
 include
/etc/letsencrypt/options-ssl-nginx.conf;
 ssl_dhparam
/etc/letsencrypt/ssl-dhparams.pem;
}


Please help me to complete the configuration at cas.properties or nginx. Thank you.

Curtis Ruck

unread,
Sep 26, 2018, 8:07:22 AM9/26/18
to CAS Community
You need to provde the Host or X-Forwarded-Host header, like this example describes: https://www.nginx.com/resources/wiki/start/topics/examples/likeapache/

This lets the backend web server know it's being reverse proxied.

Fahmi L. Ramdhani

unread,
Sep 26, 2018, 4:44:57 PM9/26/18
to CAS Community
Thanks Curtis, the problem is resolved in the site configuration (nginx).

Baba Ndiaye

unread,
Dec 21, 2021, 5:34:33 AM12/21/21
to CAS Community, Fahmi L. Ramdhani
Hello @Fahmi
i'm working on CAS with Nginx redirect like you it's done but the website display is slow (50s). Can you give some solutions for this. I'm using Apereo CAS 6.4.4

Reply all
Reply to author
Forward
0 new messages