Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable me to run on kubernetes behind reverse proxy #120

Open
MarcSkovMadsen opened this issue Oct 12, 2022 · 4 comments
Open

Enable me to run on kubernetes behind reverse proxy #120

MarcSkovMadsen opened this issue Oct 12, 2022 · 4 comments
Assignees
Labels
enhancement New feature or request question Further information is requested

Comments

@MarcSkovMadsen
Copy link

MarcSkovMadsen commented Oct 12, 2022

I would like to tryout notebooker deployed on kubernetes.

For quick exploration purposes I just run the command

mkdir -p /home/jovyan/shared/.analytics-workspace/.mongodb;conda install -y -c anaconda mongodb=6.0.2;mongod --dbpath /home/jovyan/shared/.analytics-workspace/.mongodb &pip install notebooker;python -m ipykernel install --user --name=notebooker_kernel;notebooker-cli --mongo-host localhost:27017 start-webapp --port 11828

inside my one docker container.

The container runs and deployes fine.

But I cannot deploy to "/" as this path serves other purposes. I need to deploy to /some-subpath. So when I got to

https://domain/some-subpath

I see

image

I.e. I get a 404 not found

[2022-10-12 11:58:38] "GET /mt-uk-mongodb-notebooker HTTP/1.1" 404 331 0.001099

With other frameworks I deploy like Panel, Streamlit, Dash, Fast Api and Flask I can specify some --prefix to the server application.

But it seems not available with notebooker? Could you add it?

@jonbannister
Copy link
Collaborator

Thank you for the detailed requests! If you are able to try a manual installation from a branch, I would love to hear if the changes on support-url-prefix have (or, will have) solved your problem.

Cheers
Jon

@MarcSkovMadsen
Copy link
Author

It does not work. Though some things seem improved.

command = (
    "mkdir -p /home/jovyan/shared/.analytics-workspace/.mongodb;"
    "conda install -y -c anaconda mongodb=6.0.2;"
    "mongod --dbpath /home/jovyan/shared/.analytics-workspace/.mongodb &"
    "pip install git+https://github.com/man-group/notebooker.git@support-url-prefix;"
    "python -m ipykernel install --user --name=notebooker_kernel;"
    "notebooker-cli --mongo-host localhost:27017 start-webapp --port 11828 --url-prefix /mt-uk-mongodb-notebooker"
)

image

10.86.104.39 - - [2022-10-12 16:02:24] "GET /mt-uk-mongodb-notebooker/ HTTP/1.1" 200 5504 0.015893
10.86.104.39 - - [2022-10-12 16:02:24] "GET /mt-uk-mongodb-notebooker/node_modules/fomantic-ui/dist/semantic.css HTTP/1.1" 404 331 0.000997
10.86.104.39 - - [2022-10-12 16:02:24] "GET /mt-uk-mongodb-notebooker/node_modules/jquery/dist/jquery.min.js HTTP/1.1" 404 331 0.000806
10.86.104.39 - - [2022-10-12 16:02:24] "GET /mt-uk-mongodb-notebooker/node_modules/bootstrap-table/dist/themes/semantic/bootstrap-table-semantic.js HTTP/1.1" 404 331 0.000896
10.86.104.39 - - [2022-10-12 16:02:24] "GET /mt-uk-mongodb-notebooker/node_modules/datatables/media/js/jquery.dataTables.min.js HTTP/1.1" 404 331 0.002328
10.86.104.39 - - [2022-10-12 16:02:24] "GET /mt-uk-mongodb-notebooker/node_modules/fomantic-ui/dist/semantic.js HTTP/1.1" 404 331 0.000803
10.86.104.39 - - [2022-10-12 16:02:24] "GET /mt-uk-mongodb-notebooker/node_modules/datatables/media/css/jquery.dataTables.min.css HTTP/1.1" 404 331 0.000811
10.86.104.39 - - [2022-10-12 16:02:24] "GET /mt-uk-mongodb-notebooker/notebooker/iframe_loading.js HTTP/1.1" 200 709 0.002653
10.86.104.39 - - [2022-10-12 16:02:24] "GET /mt-uk-mongodb-notebooker/notebooker/one_click_notebooks.css HTTP/1.1" 200 1451 0.000920
10.86.104.39 - - [2022-10-12 16:02:24] "GET /mt-uk-mongodb-notebooker/notebooker/header.js HTTP/1.1" 200 3999 0.000880
10.86.104.39 - - [2022-10-12 16:02:24] "GET /mt-uk-mongodb-notebooker/notebooker/index.js HTTP/1.1" 200 1772 0.000896
10.86.104.39 - - [2022-10-12 16:02:24] "GET /mt-uk-mongodb-notebooker/notebooker/notebooker-icon-dark.png HTTP/1.1" 200 8963 0.001079
10.86.104.39 - - [2022-10-12 16:02:42] "GET /mt-uk-mongodb-notebooker/node_modules/fomantic-ui/dist/semantic.css HTTP/1.1" 404 331 0.001345
10.86.104.39 - - [2022-10-12 16:02:42] "GET /mt-uk-mongodb-notebooker/notebooker/one_click_notebooks.css HTTP/1.1" 304 154 0.001183
10.86.104.39 - - [2022-10-12 16:02:42] "GET /mt-uk-mongodb-notebooker/node_modules/datatables/media/css/jquery.dataTables.min.css HTTP/1.1" 404 331 0.000796

@jonbannister
Copy link
Collaborator

Aha this worked for me locally - you may need to run step 3 and 5 here since you are running a local manual version: https://notebooker.readthedocs.io/en/latest/setup.html#installing-and-running-notebooker-locally

@jonbannister
Copy link
Collaborator

Hey @MarcSkovMadsen, did you make any progress on this? Happy to merge in these changes if it has addressed your issue!

@jonbannister jonbannister self-assigned this Nov 21, 2022
@jonbannister jonbannister added question Further information is requested bug Something isn't working enhancement New feature or request and removed bug Something isn't working labels Nov 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants