jupyterhub / jupyter-server-proxy

Jupyter notebook server extension to proxy web services.
https://jupyter-server-proxy.readthedocs.io
BSD 3-Clause "New" or "Revised" License
346 stars 147 forks source link

tomcat process #133

Open djangoliv opened 5 years ago

djangoliv commented 5 years ago

I want to use jupyter-server-proxy with a tomcat process (protégé https://webprotege.stanford.edu/ )

I tried with:

def setup_webprotege():
    return {
       'command': ['/usr/local/apache-tomcat9/bin/run.sh', '{port}'],
    }

The run.sh launch tomcat.

When I click on the launcher I am redirect to 'http://... /notebook/webprotege' (Good). But I see the apache-tomcat page (localhost:8080) not the process page want to see (localhost:8080/webprotege)

Is there a solution to my problem ?

I also tried with absolute_url=True but without succes.

Regards

orboan commented 3 years ago

Have you solve this? I got Tomcat working partially. I have:

c.ServerProxy.servers = {
   'Tomcat': {
    'command': ['/opt/tomcat/latest/bin/startup.sh'],
    'timeout': 30,
    'port': 8080,
    'absolute_url': False,
    'launcher_entry': {
            'title': 'Tomcat'
    }
  }
}

And Tomcat loads fine from the new menu, and once in the main tomcat page where I can see the list of deployed war files, the links for accessing each app (war files) are fine (with the /user/{username}/Tomcat/{appname} prefix path after the domain name) but once clicking on it, it makes a 302 redirection to /hub/{appname} so I get a 404 not found. Does anybody know why this 302 redirect happens and how to solve it? I found out it is a 302 in the pod logs. Thank you