Launch Gradio Block with a custom url
I want to host multiple instances of a GradioBlockon different endpoints. For example, setting a block to be accessible vialocalhost:7890/gradio/id123. I know that I can control the server name and port with the environment variables withGRADIO_SERVER_NAMEandGRADIO_SERVER_PORT, but neither is useful if I want to create multiple gradio Blocks exposed on different endpoints. How would I go about doing this?
2023-07-30T04:42:41Z
Hi@at123thanks for asking this question! You should create multiple Gradio Blocks and then mount them within a larger FastAPI application. This is described here:Sharing Your App