Sakai and multiple domain

132 views Asked by At

Recently, I constructed a website based on Sakai Open Source Project:

Everything works fine except for the following problem:

I have pointed multiple domain to my server IP. Example: domain1.com, www.domain1.com, domain2.com, www.domain2.com. All point to my server.

When I login with domain1.com and then open www.domain1.com or domain2.com, It asks for login again. Although all the domains point to the same webapps. What am i doing wrong here and how can i solve this?

2

There are 2 answers

0
Aaron Zeckoski On

You need to enable sticky sessions on your server. This is answered here: sticky session with apache web server and tomcat servers

0
samottenhoff On

Sakai sets the JSESSIONID to maintain a user's session with Sakai. If Sakai sets the cookie for www.domain1.com, then your web browser won't share the cookie with www.domain2.com.

If you set a cookie on a.example.com, and want the same session to be shared on b.example.com, you will need to modify the Sakai cookie domain to set the cookie on the global domain ".example.com" instead of setting it to the specific domain "a.example.com".