Closed Bachibouzouk closed 2 years ago
Switch from mysql to postgres database
From the container of the previous mysql based django app exectuted python manage.py dumpdata projects users dashboard > db_backup_fixture.json
python manage.py dumpdata projects users dashboard > db_backup_fixture.json
Then copied the file to the container of the new postgres based django app and executed python manag.py loaddata 'db_backup_fixture.json'
python manag.py loaddata 'db_backup_fixture.json'
There was a serialization error at first, it was due to asyncio logger, so I set the logging detail to warning to disable it and it worked then.
Switch from mysql to postgres database
From the container of the previous mysql based django app exectuted
python manage.py dumpdata projects users dashboard > db_backup_fixture.json
Then copied the file to the container of the new postgres based django app and executed
python manag.py loaddata 'db_backup_fixture.json'
There was a serialization error at first, it was due to asyncio logger, so I set the logging detail to warning to disable it and it worked then.