GCP app: https://wine-ratings-b4yojuwgbq-uc.a.run.app/
In this exercise, we will build a fastapi ML application and deploy it with continuous delivery on GCP using Cloud Run and Cloud Build..
To build a ML model, refer the colab notebook under notebooks
folder.
To validate the fastapi application locally,
docker build -t wine .
docker run --rm -it -v $(pwd):/app -p 8000:8000 wine
To deploy the fastapi application on GCP following steps were taken.
-
While creating repo, add Google Cloud Build from Marketplace.
-
Create google cloud account.
-
Create a service in
Cloud Run
adding this repo asContinuous Deploy from source repository
Add 8000 under Containers in section Container, Variables & Secrets, Connections, Security
-
App will deployed, to monitor keep checking logs.