[IPython-dev] Jupyterhub with ssl?

Bob Dougherty bobd at stanford.edu
Tue Sep 16 18:55:38 EDT 2014


Awesome! That works. Thanks Min!

On 09/16/2014 03:42 PM, MinRK wrote:
>
> It’s IPython’s websocket cross-origin checking getting confused by the 
> proxied request. If you add:
>
> |--NotebookApp.allow_origin=[https://your_host](https://your_host)[:port]
> |
>
> (or ‘*’)
>
> to the args passed to the single-user servers, it should allow the 
> connection:
>
> |jupyterhub --Spawner.cmd="['jupyterhub-singleuser', '--NotebookApp.allow_origin=https://your_host[:port]']"
> |
>
> I opened a PR <https://github.com/ipython/ipython/pull/6480> to patch 
> the bug in origin checking.
>
> -MinRK
>
>>
> On Mon, Sep 15, 2014 at 4:26 PM, MinRK <benjaminrk at gmail.com 
> <mailto:benjaminrk at gmail.com>> wrote:
>
>     I'll look into it. Might be something wrong in the proxy config.
>
>     On Mon, Sep 15, 2014 at 12:26 PM, Bob Dougherty <bobd at stanford.edu
>     <mailto:bobd at stanford.edu>> wrote:
>
>         Thanks Matthias. Unfortunately, I get the same error on
>         Firefox. And ipython without the hub works fine with ssl on
>         Chrome. Does ssl through jupyterhub work for you? If so, what
>         version of node are you running?
>
>
>         On 09/15/2014 12:19 PM, Matthias Bussonnier wrote:
>>
>>         Le 15 sept. 2014 à 21:13, Bob Dougherty <bobd at stanford.edu
>>         <mailto:bobd at stanford.edu>> a écrit :
>>
>>>         Hi All,
>>>
>>>         Is anyone else running Jupyterhub through ssl? I'm
>>>         struggling to get it working. Everything works fine except
>>>         for the websocket connection. I.e., I can log in through the
>>>         Jupyterhub login page, create, edit, save notebooks, etc.
>>>         But trying to execute a code cell just hangs. Chrome shows
>>>         this in the js console:
>>>
>>>             Default extension for cell metadata editing loaded.
>>>             Raw Cell Format toolbar preset loaded.
>>>             Slideshow extension for metadata editing loaded.
>>>             Kernel started: 398fe67c-856b-48c5-b2d7-242bfa70f2e1
>>>             Starting WebSockets:
>>>             wss://spgr.stanford.edu:8080/user/bobd/api/kernels/398fe67c-856b-48c5-b2d7-242bfa70f2e1
>>>             Uncaught InvalidStateError: Failed to execute 'send' on
>>>             'WebSocket': Still in CONNECTING state.
>>>             :8080/user/bobd/static/services/kernels/js/kernel.js:248
>>>
>>>         Everything *does* work when I don't use ssl, and ssl works
>>>         (with the same cert and key) when I run the notebook
>>>         directly without jupyterhub. So I suspect it's a problem
>>>         with the nodejs proxy of wss. I'm running node v0.10.25 and
>>>         the current master of jupyterhub and ipython.
>>>
>>>         Any help on debugging this would be much appreciated!
>>
>>         I got that on chrome, without jupyter-hub. Solved by itself
>>         after 1 week of holidays.
>>         My opinion is that it's a bug on chrome that sometime refuses
>>         to open 3 web socket connexions at the same time,
>>         as when it did happen firefox was happy with my setup.
>>
>>         -- 
>>         M
>>
>>
>>>
>>>         thanks,
>>>         bob
>>>
>>>         _______________________________________________
>>>         IPython-dev mailing list
>>>         IPython-dev at scipy.org <mailto:IPython-dev at scipy.org>
>>>         http://mail.scipy.org/mailman/listinfo/ipython-dev
>>
>>
>>
>>         _______________________________________________
>>         IPython-dev mailing list
>>         IPython-dev at scipy.org  <mailto:IPython-dev at scipy.org>
>>         http://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
>         _______________________________________________
>         IPython-dev mailing list
>         IPython-dev at scipy.org <mailto:IPython-dev at scipy.org>
>         http://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
>
>
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> http://mail.scipy.org/mailman/listinfo/ipython-dev

-- 
Robert F. Dougherty, PhD
Research Director
Stanford Center for Cognitive and Neurobiological Imaging
70 Jordan Hall  *  Stanford CA 94305  *  650-725-0051
http://www.stanford.edu/~bobd

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140916/82ec2d73/attachment.html>


More information about the IPython-dev mailing list