As I was following the documentation regarding of deploying in app-platform, I am using flask and I successfully deployed the application. It showed the login UI and then when I attempt to login, internal error problem. I tracked the runtime logs showing “no table user exist”. I tried to check in my cli the mysql connection using the flags and after I checked the user and other table existed, this is very weird problem. How can I fix this?
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Hey there! 👋
After deploying your app, do you by any chance run your database migrations as well?
If your app requires migrations to set up tables (e.g., using Flask-Migrate or SQLAlchemy), you need to make sure that these migrations are run as part of your deployment/run process. App Platform deployments don’t automatically run migrations unless you include a step for it.
If you haven’t already, add a migration step to your
start
ordeploy
command in the App Platform configuration. For example:You can change the
gunicorn
based on your needs if needed.Let me know how it goes!
- Bobby