mirror of
https://github.com/SWivid/F5-TTS.git
synced 2025-12-31 23:17:56 -08:00
Add root_path argument to support reverse proxies
This commit is contained in:
@@ -831,11 +831,11 @@ If you're having issues, try converting your reference audio to WAV or MP3, clip
|
||||
help="Share the app via Gradio share link",
|
||||
)
|
||||
@click.option("--api", "-a", default=True, is_flag=True, help="Allow API access")
|
||||
def main(port, host, share, api):
|
||||
@click.option("--root_path", "-r", default=None, type=str, help="The root path of the gradio application if it's not served from the root (\"/\") of the domain. Set this value if the application is behind a reverse proxy that forwards the request to a subdirectory of the domain.")
|
||||
def main(port, host, share, api, root_path):
|
||||
global app
|
||||
print("Starting app...")
|
||||
app.queue(api_open=api).launch(server_name=host, server_port=port, share=share, show_api=api)
|
||||
|
||||
app.queue(api_open=api).launch(server_name=host, server_port=port, share=share, show_api=api, root_path=root_path)
|
||||
|
||||
if __name__ == "__main__":
|
||||
if not USING_SPACES:
|
||||
|
||||
Reference in New Issue
Block a user