Hello,

I realize I never properly 'closed' this case so if anyone has this issue I 
managed to solve it with Régis advice. You can find below the way to manage 
SSO with docker devstack installation. 

To resolve this Regis explained in his post, that two settings needs to be 
set.
LOGIN_REDIRECT_WHITELIST & SESSION_COOKIE_DOMAIN 
Please refer to his post to understand how to set them.

The only thing is that for the docker devstack installation the setting 
SESSION_COOKIE_DOMAIN has to be set in the file 
lms/envs/devstack_docker.py. It was not taken in account inside the 
lms.env.json or cms.env.json.

I hope it can help some of you with the same issue.

Again thank you very much Régis for taking to the time to answer me.

Best regards,
Lucas



Le mercredi 22 mai 2019 12:12:55 UTC+2, Lucas Rittié a écrit :
>
> Hello Régis,
>
> Thanks again for your answer, I tried with .mydomain.com and several 
> other config. Yet I still have this error message. Somehow I'm getting in a 
> redirection loop between the lms and studio.
> I see 5 tries to redirect from the lms to the studio then the server 
> stopped trying and I get the error (seen in previous post) from the browser 
>
> In the lms logs I see that my user is well authenticated ( *Login success 
> - staff (st...@example.com <st...@example.com>)*) and then the server 
> loops with HTTP GET method on the path "GET 
> /login?next=https%3A%2F%2Fstudio.mydomain%2Fcourse%2F HTTP/1.1" 302 0
>
> I'll try to re-check my redirect urls settings in lms.env & cms.env json. 
> But if you have some insights on this issue it would again greatly 
> appreciated ^^
>
> Thank you !
> Lucas
>
> Le lundi 20 mai 2019 12:13:49 UTC+2, Régis Behmo a écrit :
>>
>> > I believe this maybe has to do with the setting SESSION_COOKIE_DOMAIN 
>> > In my case I have my lms hosted on MYDOMAIN.COM and studio on 
>> > STUDIO.MYDOMAIN.COM so I have set SESSION_COOKIE_DOMAIN to 
>> > MYDOMAIN.COM 
>>
>> You were almost there :) The SESSION_COOKIE_DOMAIN should be 
>> ".mydomain.com" (mind the starting dot). 
>>
>> --- 
>> Régis 
>>
>>
>>
>> On 2019-05-20 11:54, Lucas Rittié wrote: 
>> > Hello Régis, 
>> > 
>> > Thanks for your quick reply, indeed I needed to make change to the 
>> > settings you described so now the redirection is almost ok but I have 
>> > an error when trying to access studio webpages. Below is the scenario 
>> > and the error 
>> > 
>> > Now I go to studio.myopenedx.com and click on connect --> I'm 
>> > redirected to the lms and enter my credentials to login --> I get 
>> > redirect to the studio but I can't open any pages, I get the following 
>> > error from my web browser and not from django server 
>> > 
>> > The page isn’t redirecting properly 
>> > An error occurred during a connection to studio.mydomain.com 
>> >     This problem can sometimes be caused by disabling or refusing to 
>> > accept cookies. 
>> > 
>> > I did clear cookies, history, cache on my web browsers but I still 
>> > have this issue. 
>> > 
>> > I believe this maybe has to do with the setting SESSION_COOKIE_DOMAIN 
>> > In my case I have my lms hosted on MYDOMAIN.COM and studio on 
>> > STUDIO.MYDOMAIN.COM so I have set SESSION_COOKIE_DOMAIN to 
>> > MYDOMAIN.COM 
>> > 
>> > Should I host the lms under a subdomain as well as for studio ? Or is 
>> > there something else I'm missing ? 
>> > 
>> > Thanks in advance for your help, 
>> > It's much appreciated 
>> > 
>> > Best regards, 
>> > Lucas 
>> > 
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"General Open edX discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to edx-code+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/edx-code/390d7e58-085a-4aa6-a4ee-4e6ee19a8a2b%40googlegroups.com.

Reply via email to