Hi folks,
I’m trying to view an HTML file from the file system via JupyterLab on JupyterHub with GitHub authentication. The HTML file relies on CSS and JavaScript files which are in the same directory on the lab server’s file system. Although I can view the HTML file, the CSS and JS files fail to load.
This happens if I click on the HTML file and and try Open With > HTML viewer. or if I try Open In New Browser Tab.
Looking at the developer console in chrome, I can see the requests for the CSS and JS files are getting redirected to the hub login page. So I’m guessing this has something to do with my authentication not getting passed through to these requests somehow, but that’s where I run out of my depth I’m afraid.
Any help or advice appreciated. For context, this came up because I’m wanting to use Jupyter Book to build HTML sites and reports from Jupyter notebooks, and I’d like to be able to run the Jupyter Book build on my JupyterLab server and preview the HTML outputs locally before pushing any changes to the remote github repo for deployment.
Cheers,
Alistair