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

move db migrations to initContainers: #2449

Merged
merged 5 commits into from
Mar 3, 2025

Conversation

ikreymer
Copy link
Member

@ikreymer ikreymer commented Mar 1, 2025

- should avoid gunicorn worker timeouts for long running migrations, also fixes #2439
- add main_migrations as entrypoint to just run db migrations, using existing init_ops() call
- first run 'migrations' container with same resources as 'app' and 'op'
- additional typing for initializing db
- fixes #2447
ikreymer added a commit that referenced this pull request Mar 1, 2025
- don't wait for languages to be ready to render UI, as this can result
in empty page if backend can not be reached.
- catch if /api/settings returns an invalid response to show 'backend
initializing' message
- will support initContainers where backend may return 5xx error while
backend is initializing, via #2449

Note: this results in locale picker showing all available locales if
backend is not available, not just filtered ones, but I think that's a
reasonable trade-off.
Copy link
Member

@tw4l tw4l left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested and working well! One suggestion to remove some now-legacy code to avoid any confusion around db_inited moving forward.

@ikreymer ikreymer merged commit e13c3bf into main Mar 3, 2025
22 checks passed
@ikreymer ikreymer deleted the issue-2447-init-container-migrations branch March 3, 2025 21:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Change]: Move DB migrations to initContainers [Bug]: upgrade to 1.14.0 or 1.14.1 fails on hanging migration
2 participants