WIP: Dockerize the server and its supporting services #144
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is a PR to discuss the solution to the issue with migrations.
It is unclear why the migrations keep failing, but they won't pass if the
recipient_identifier
isa varchar(712). At least not in the dockerized version of mysql 8.4. It fails on creating the
index, as the index is larger than 3072.
The database is utf8, and collation is correct.
When we set this column to be only 512 long, as it is at the end of running all migrations anyway,
the index can be created.
The failure is:
This PR proposes two alternative solutions to this:
The option 1 was reverted and can only be witnessed in the git history of this PR. It has a severe
downside: production builds, and other builds will run this new migration, but
will fail, as the index exsists. Neither MySQL nor django migrations have a
mechanism to "CREATE INDEX .. IF NOT EXISTS" like postgres or mariadb do.
Option 2 has downside that it alters migrations that have already been applied. Which is normally
a bad practice.