I implemented and tested the project locally with the same data in database as I have in GCP. But when I deploy my project in GCP it returns 502 every time. How can I fix this issue?
app.yaml:
runtime: python
env: flex
entrypoint: gunicorn -b :$PORT main:app
runtime_config:
python_version: 3.9
# This sample incurs costs to run on the App Engine flexible environment.
# The settings below are to reduce costs during testing and are not appropriate
# for production use. For more information, see:
# https://cloud.google.com/appengine/docs/flexible/python/configuring-your-app-with-app-yaml
manual_scaling:
instances: 1
resources:
cpu: 1
memory_gb: 0.5
disk_size_gb: 10
connection to db:
from sqlalchemy import create_engine
engines = {"rdbms": create_engine('postgresql://<user>:<password>@<public ip of instance>:5432/books_reviews')}
P.S. I only started learning GCP, so sorry if this is a stupid question. P.P.S. Repo url: https://github.com/LilJohny/BookReviewsAPI