Repo Url
: This is the URL of the Github repository that contains the code for the service. For this example, the repo url is https://github.com/truefoundry/getting-started-examplesPath to build context
: This is the path to the directory in the Github repository that contains the code for the service. For this example, the path to the build context is ./deploy-model-with-fastapi/
Command
: This is the command to run the service. For this example, the command is uvicorn app:app --host 0.0.0.0 --port 8000
Port
: This is the port on which the service will be exposed. Since we have mentioned port 8000 in the command above, so we need to specify the port here as 8000.Submit
, your deployment will be successful in a few seconds, and your service will be displayed as active (green), indicating that it’s up and running.
You can view all the information about your service following the steps below:
How to omit certain files from being built and deployed?
.tfyignore
file follows the same rules as the .gitignore
file..gitignore
file, you don’t need to create a .tfyignore
file. Truefoundry will automatically detect the files to ignore.Where is the docker image built?
What changes when you deploy Streamlit / Gradio apps ?
I cannot access the URL even after exposing the port
0.0.0.0
and not localhost / 127.0.0.1.
.This is commonly manifested via command line arguments like gunicorn --bind 0.0.0.0:8000
or uvicorn --host 0.0.0.0 --port 8000
.