I have JupyterHub running on Amazon EKS. I can access my hub and notebooks with some custom authentication I’ve configured. However, I’d like to embed the notebooks in an iframe and I’m running into trouble. When I try to make a ccross domain request to jupyterhub, the browser sends a request with the OPTIONS method, and jupyterhub responds with an HTTP 405 “Method Not Allowed”.
I dug into the jupyterhub source and I can’t see that LogoutHandler, BaseHandler, or RequestHandler define an options
method so I think I’m getting a response from _unimplemented_method
.
Based on this reading of the code, the reason for the 405 seems obvious, but a lot of people online seem to have working setups of this sort working (with the appropriate Content-Security-Policy and Access-Control-Allow-Origin headers). So… what gives? How does anyone have this working when cors preflight requires an OPTIONS response, and jupyterhub doesn’t seem to handle OPTIONS requests?