commuter icon indicating copy to clipboard operation
commuter copied to clipboard

Allow deploying commuter on a basepath

Open rgbkrk opened this issue 8 years ago • 6 comments

In order to deploy commuter as a service for JupyterHub (and generally on the configurable HTTP proxy), we need the ability to run commuter on a prefix.

/cc @minrk @cabhishek

rgbkrk avatar May 15 '17 17:05 rgbkrk

Originally reported on #94, silly me.

rgbkrk avatar May 15 '17 17:05 rgbkrk

~~Working on this today in hopes we can deploy it with JupyterHub this week.~~ Didn't happen, probably won't work on this again.

rgbkrk avatar May 30 '17 19:05 rgbkrk

Hello, just curious about this (and #94). Support for configuring the root path/prefix would enable a number of different deployment options.

chuckpr avatar Jul 23 '19 02:07 chuckpr

@rgbkrk I'm just looking at this now. I'm wondering how you were imagining it being implemented?

It appears there is an Express backend app, hosting a Next frontend app.

I've tried the obvious:

    const baseURI = process.env.COMMUTER_SOMEVAR || '/';
    app.use(baseURI, router);

and it isn't working. That's typically that all that would be required in Express.

Where are the complications in implementing this and where should I start looking?

There is experimental support now in Next for a configurable basePath, which allows the frontend to be dynamically aware of it's mount point.

groodt avatar May 18 '20 00:05 groodt

That configurable basePath is probably the right starting point, but I haven't touched this code base or next for a long time. 😅

rgbkrk avatar May 28 '20 16:05 rgbkrk

Thanks @rgbkrk

I'll have to look into it a bit more. Migrating commuter from express to next might take a bit of work.

groodt avatar May 31 '20 23:05 groodt