

def remount(base):
    "\n    Remount current app to new app at base mountpoint such as '/demo'\n    This enables different root path such as required by web server proxy\n    "
    if (not base):
        return bottle.app()
    oldApp = bottle.app.pop()
    newApp = bottle.app.push()
    newApp.mount(base, oldApp)
    return newApp

dataset/ETHPy150Open saltstack/halite/halite/server_bottle.py remount/original