To prevent migration conflicts between different developers, we decided to avoid deploying any migrations files; and rather run
makemigrations after deployment.
But every time we deploy, the existing migration files are deleted and a new
001_initial.py file is created, leading to a
Why is Digital Ocean deleting the existing migration files rather than running a new makemigration and appending the model changes to the existing files? We run
python manage.py makemigrations && python manage.py migrate before the run commands.
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.