To give context I have jupyterhub instance sitting behind my companies api gateway, and I am using the API of the hub and server exclusively. I am running into an issue when making a request to the jupyter server api where the response has two Access-Control-Allow-Origin header values. I believe the issue is due to my gateway and the jupyterhub gateway both injecting Access-Control-Allow-Origin headers into the response. I was wondering if there was a way to disable the hub injecting the additional headers to the response.
Here is the API workflow.
- Start a server via a custom service communicating with the hub.
- Request a API token from a custom service communicating with the hub.
- Use token to make requests against the server instance (via the hub proxy i.e. /user/{user_id}/.
- All server requests get an additional Access-Control-Allow-Origin header added on.
I have already tried the solution discussed here. Which only supported my suspicions because the additional header value change to the one I added (i.e. *
).