chirag aggarwal
chirag aggarwal

Reputation: 93

FASTAPI app not working with GCP APP engine

I am trying to deploy a fastAPI app with python 7 to the GCP app engine. After configuring the app.yaml file app is working fine with dev_server while using the command dev_server app.yaml. But after deploying the app using gcloud app deploy and followed by gcloud app browser I am getting an access URL.

After hitting the URL I am facing an error as below

enter image description here

Note - I am using a quick lab for learning the deployment. And things are working fine with flask app but not working with the FastApi app.

Upvotes: 0

Views: 1745

Answers (1)

Sergio NH
Sergio NH

Reputation: 185

Since you already used the devapp_server command in order to test your application and it works, as a suggestion in order to check why you are facing this issue, you can try to see your App’s logs in the Developer Console from GCP.

Also, can be checked with the Logs Viewer and the console using the command line:

gcloud app logs tail

Check this documentation for further information about writing and viewing logs from your app.

Moreover I could find a tutorial about Deploying FastAPI in AppEngine. Maybe it could help you to develop it through this way also.

Upvotes: 3

Related Questions