2

I want to change the url prefix in apache superset. As of now in the browser it looks like '<my_site>/superset/welcome or <my_site>/superset/sqllab . can we change this to something like <my_site>/my_name/welcome etc.

Also how can we add a new menu item in top nav bar ?

jsc_1999841
  • 51
  • 1
  • 4
  • Does this answer your question? [URL prefix for Superset](https://stackoverflow.com/questions/50808107/url-prefix-for-superset) – emesday Sep 28 '22 at 14:24

1 Answers1

0

For your specific requirement, you can do that by overriding the route_base variable in the Superset class inside /views/core.py

It would look something like:

class Superset(BaseSupersetView):  # pylint: disable=too-many-public-methods
    """The base views for Superset!"""
    route_base = "/my-app"  <=========
akzarma
  • 179
  • 11
  • i did not find that variable in the file. Is it something that i have to add as new? – jsc_1999841 Nov 09 '22 at 18:44
  • That's a attribute present in super class BaseView in flask app builder. Check here: https://github.com/dpgaspar/Flask-AppBuilder/blob/master/flask_appbuilder/baseviews.py#L117 – akzarma Nov 09 '22 at 20:55