Run database migrations in job to allow scaling #17

Merged
tteichler merged 13 commits from add-migrations-job into master 2021-03-19 22:08:10 +01:00
Owner
No description provided.
Author
Owner

added 1 commit

Compare with previous version

added 1 commit <ul><li>24ec8ec5 - Add job for migrations</li></ul> [Compare with previous version](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=5948&start_sha=ad6578eec7a5be7bd7a08a094740c11d22870f57)
Author
Owner

Waiting for AlekSIS/official/AlekSIS-Core!551

Waiting for AlekSIS/official/AlekSIS-Core!551
Author
Owner

assigned to @nik

assigned to @nik
Author
Owner

added 1 commit

Compare with previous version

added 1 commit <ul><li>074d79de - Fix run_mode</li></ul> [Compare with previous version](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=5971&start_sha=24ec8ec5b70603cdfc1a3cd15e96f0f3db765b40)
Author
Owner

added 5 commits

  • 074d79de...04af6e84 - 4 commits from branch master
  • 25af2294 - Merge branch 'master' into add-migrations-job

Compare with previous version

added 5 commits <ul><li>074d79de...04af6e84 - 4 commits from branch <code>master</code></li><li>25af2294 - Merge branch &#39;master&#39; into add-migrations-job</li></ul> [Compare with previous version](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=5978&start_sha=074d79dee384df7aa5676aa81a2fd74c1413690c)
Owner
      - name: {{ include "aleksis.fullname" . }}-prepare

(For consistency with naming in docker-startup)

```suggestion:-0+0 - name: {{ include "aleksis.fullname" . }}-prepare ``` (For consistency with naming in `docker-startup`)
Owner

This is wrong. It shadows docker-startup, and the prepare run mode will never run. In doing so, it misses out on parts, e.g. on createinitialrevisions.

This is wrong. It shadows `docker-startup`, and the `prepare` run mode will never run. In doing so, it misses out on parts, e.g. on `createinitialrevisions`.
Owner

Please check when the superuser is created. If it is created in a migration (or post-migrate hook), this is correct, but in that case, please strip this environment from all other contianers as they do not need it anymore in that case. If it is reated outside migrations, remove this environment from the job ocntianer instead.

Please check when the superuser is created. If it is created in a migration (or post-migrate hook), this is correct, but in that case, please strip this environment from all other contianers as they do not need it anymore in that case. If it is reated outside migrations, remove this environment from the job ocntianer instead.
Owner

The full prepare mode also generates static files, so you need to mount all volumes.

The full `prepare` mode also generates static files, so you need to mount all volumes.
Owner

How is this job linked to the deployment? How do you ensure it is run whenever a new image version is pulled, or whatever might cause the database to get outdated? In other words: When is this job run, and how is that defined?

How is this job linked to the deployment? How do you ensure it is run whenever a new image version is pulled, or whatever might cause the database to get outdated? In other words: When is this job run, and how is that defined?
Owner

The necessary changes to disable preparation in all othe rcontainers are missing.

The necessary changes to disable preparation in all othe rcontainers are missing.
Author
Owner

resolved all threads

resolved all threads
Author
Owner

changed this line in version 5 of the diff

changed this line in [version 5 of the diff](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=5986&start_sha=25af2294fe98f53bef4098d518d26f11218787f5#df95af25829841d680add7f88bf753787e94980b_11_11)
Author
Owner

changed this line in version 5 of the diff

changed this line in [version 5 of the diff](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=5986&start_sha=25af2294fe98f53bef4098d518d26f11218787f5#df95af25829841d680add7f88bf753787e94980b_14_14)
Author
Owner

added 1 commit

  • be4819f4 - Mount all volumes in job

Compare with previous version

added 1 commit <ul><li>be4819f4 - Mount all volumes in job</li></ul> [Compare with previous version](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=5986&start_sha=25af2294fe98f53bef4098d518d26f11218787f5)
Author
Owner

fixed

fixed
Author
Owner

resolved all threads

resolved all threads
Author
Owner

added 1 commit

Compare with previous version

added 1 commit <ul><li>ce563a24 - Mount all volumes in job</li></ul> [Compare with previous version](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=5988&start_sha=be4819f4fc2c25db5c565451f1a8637af8b3827a)
Author
Owner

added 1 commit

Compare with previous version

added 1 commit <ul><li>d43c743d - Add gitignore</li></ul> [Compare with previous version](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=6004&start_sha=ce563a24cf6e3060872014f60742fc878f2feba9)
Author
Owner

added 2 commits

  • a740f411 - 1 commit from branch master
  • 6ef5d697 - Merge branch 'master' into add-migrations-job

Compare with previous version

added 2 commits <ul><li>a740f411 - 1 commit from branch <code>master</code></li><li>6ef5d697 - Merge branch &#39;master&#39; into add-migrations-job</li></ul> [Compare with previous version](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=6007&start_sha=d43c743d722256f9888bc6b310a6cf36dbe7eb4c)
Author
Owner

added 1 commit

Compare with previous version

added 1 commit <ul><li>189dc2ba - Fix indentation</li></ul> [Compare with previous version](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=6008&start_sha=6ef5d697214d9325a78d4188a723eb23812bc75f)
Author
Owner

changed this line in version 10 of the diff

changed this line in [version 10 of the diff](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=6009&start_sha=189dc2ba59ff1f36408a9c18ec97253cf28c8292#df95af25829841d680add7f88bf753787e94980b_62_47)
Author
Owner

added 1 commit

Compare with previous version

added 1 commit <ul><li>1d358572 - Fix indentation</li></ul> [Compare with previous version](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=6009&start_sha=189dc2ba59ff1f36408a9c18ec97253cf28c8292)
Author
Owner

added 1 commit

Compare with previous version

added 1 commit <ul><li>b3be882b - Fix values</li></ul> [Compare with previous version](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=6013&start_sha=1d3585726ac3c3ae0fff524893e51895e3941061)
Author
Owner

added 1 commit

Compare with previous version

added 1 commit <ul><li>5c48f686 - Run after upgrade</li></ul> [Compare with previous version](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=6015&start_sha=b3be882b8de39d86195d818243e3d750613d270c)
Author
Owner

added 1 commit

Compare with previous version

added 1 commit <ul><li>27bfe0a0 - Fix indentation of volumes</li></ul> [Compare with previous version](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=6016&start_sha=5c48f686de6f5f66dd20644292c7800f3f49562c)
Author
Owner

added 2 commits

  • 519846f3 - 1 commit from branch master
  • b35adfad - Merge branch 'master' into add-migrations-job

Compare with previous version

added 2 commits <ul><li>519846f3 - 1 commit from branch <code>master</code></li><li>b35adfad - Merge branch &#39;master&#39; into add-migrations-job</li></ul> [Compare with previous version](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=6017&start_sha=27bfe0a0558cbf8dcdc142a294d89e1fa40f4931)
Author
Owner

added 1 commit

  • daaf7251 - Remove apps path from gitignore

Compare with previous version

added 1 commit <ul><li>daaf7251 - Remove apps path from gitignore</li></ul> [Compare with previous version](/AlekSIS/Deployment/AlekSIS-k8s/-/merge_requests/5/diffs?diff_id=6020&start_sha=b35adfadd5f974805c5386a37d43fc5c30d79503)
Owner

mentioned in commit d58e38b069

mentioned in commit d58e38b069b92d01a070d0b80d098d7edd3e9c5b
nik merged commit d58e38b069 into master 2021-03-19 22:08:11 +01:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
aleksis/AlekSIS-k8s!17
No description provided.