Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker Deployment removes all data from database #673

Closed
4 tasks done
pravin-ptg opened this issue Apr 16, 2024 · 2 comments
Closed
4 tasks done

Docker Deployment removes all data from database #673

pravin-ptg opened this issue Apr 16, 2024 · 2 comments

Comments

@pravin-ptg
Copy link

pravin-ptg commented Apr 16, 2024

Issue summary

When running on Production AWS , everytime we run the docker , it removes all the data from app
Before opening this issue, I have:

  • Upgraded to the latest version of the @shopify packages
    • Affected @shopify/shopify-* package and version:
    • Node version:
    • Operating system:
  • Set { logger: { level: LogSeverity.Debug } } in my configuration
  • Found a reliable way to reproduce the problem that indicates it's a problem with the package
  • Looked for similar issues in this repository

Expected behavior

What do you think should happen?
It should show the previous data as it is

Actual behavior

It is removing all the data from app evertime the docker is run
What actually happens?

Steps to reproduce the problem

  1. deploy this docker file on AWS
  2. make changes to app and redeploy

We also tried removing this line in production , but than it shows the tables are already exist and throwing errors during deployment
You'll probably want to remove this in production, it's here to make it easier to test things!
RUN rm -f prisma/dev.sqlite

@matteodepalo
Copy link
Contributor

matteodepalo commented Apr 18, 2024

Hi @pravin-ptg, thank you for opening the issue and for the feedback.
We're planning to improve how deploying works. In the meanwhile may I recommend switching away from sqlite so you don't rely on a file in the codebase? You can also try changing your docker-start script to not run setup.

@pravin-ptg
Copy link
Author

Hi @pravin-ptg, thank you for opening the issue and for the feedback. We're planning to improve how deploying works. In the meanwhile may I recommend switching away from sqlite so you don't rely on a file in the codebase? You can also try changing your docker-start script to not run setup.

Hello Matt, Yes , we have already started replacing it with MySQL for now.
Thank You

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants