03 Changing your Portal's hostname
The default uPortal & CAS configuration is setup using localhost:8080 as the portal host-name and port. To switch hostnames there are several changes that need to be made. For the example below lets assume the configuration is changing from localhost:8080 to my.school.edu:80
uportal-impl/src/main/resources/properties/security.properties
There are two lines that need to be updated in security.properties. Note that on each line the host name needs to be changed in TWO places.
Change One
logoutRedirect.root=http://localhost:8080/cas/logout?url=http://localhost:8080/uPortal/Login
becomes
logoutRedirect.root=http://my.school.edu/cas/logout?url=http://my.school.edu/uPortal/Login
Change Two
org.jasig.portal.channels.CLogin.CasLoginUrl=http://localhost:8080/cas/login?service=http://localhost:8080/uPortal/Login
becomes
org.jasig.portal.channels.CLogin.CasLoginUrl=http://my.school.edu/cas/login?service=http://my.school.edu/uPortal/Login
uportal-war/src/main/webapp/WEB-INF/web.xml
There are four lines that need to be updated in web.xml
Change One
<param-name>edu.yale.its.tp.cas.proxyUrl</param-name> <param-value>https://localhost:8080/cas/proxy</param-value>
becomes
<param-name>edu.yale.its.tp.cas.proxyUrl</param-name> <param-value>https://my.school.edu/cas/proxy</param-value>
Change Two
<param-name>edu.yale.its.tp.cas.client.filter.validateUrl</param-name> <param-value>http://localhost:8080/cas/serviceValidate</param-value>
becomes
<param-name>edu.yale.its.tp.cas.client.filter.validateUrl</param-name> <param-value>http://my.school.edu/cas/serviceValidate</param-value>
Change Three
<param-name>edu.yale.its.tp.cas.client.filter.serverName</param-name> <param-value>localhost:8080</param-value>
becomes
<param-name>edu.yale.its.tp.cas.client.filter.serverName</param-name> <param-value>my.school.edu</param-value>
Change Four
<param-name>edu.yale.its.tp.cas.client.filter.proxyCallbackUrl</param-name> <param-value>http://localhost:8080/uPortal/CasProxyServlet</param-value>
becomes
<param-name>edu.yale.its.tp.cas.client.filter.proxyCallbackUrl</param-name> <param-value>http://my.school.edu/uPortal/CasProxyServlet</param-value>