Skip to content

[4.5.X] Refactor DB cache management in runtests and runmigration#299

Merged
yvaucher merged 2 commits intocamptocamp:release-4.5.Xfrom
yvaucher:4.5.X-refactor-cachedb
Feb 5, 2025
Merged

[4.5.X] Refactor DB cache management in runtests and runmigration#299
yvaucher merged 2 commits intocamptocamp:release-4.5.Xfrom
yvaucher:4.5.X-refactor-cachedb

Conversation

@yvaucher
Copy link
Copy Markdown
Contributor

@yvaucher yvaucher commented Oct 15, 2024

Backport of #252 for the 4.5.X branch

Gives most variables a default value making them changable with var=${var:=default}

Extract db restore and dump in a separate db.sh file.

Change (default) value for cachedb directory to make it easier to set a volume on it.

Add || true in runmigration when doing ls -v to ignore the error status and set an empty CACHED_DUMP variable.

Improve slightly the messages.

This should fix issue of renaming in bin/runmigration of the dump file name which stayed the same as the restored one. (and in worst case to an empty filename on github actions)

@yvaucher yvaucher force-pushed the 4.5.X-refactor-cachedb branch 3 times, most recently from 4f1457b to 25d214d Compare October 15, 2024 15:30
@yvaucher yvaucher changed the title Refactor DB cache management in runtests and runmigration [4.5.X] Refactor DB cache management in runtests and runmigration Oct 15, 2024
@yvaucher yvaucher force-pushed the 4.5.X-refactor-cachedb branch from 25d214d to 7c8e8ff Compare October 15, 2024 16:07
In order to extract the DB dump from the image we want this folder to be standalone especially in the CI
@yvaucher yvaucher force-pushed the 4.5.X-refactor-cachedb branch from 7c8e8ff to d965672 Compare October 17, 2024 13:51
@yvaucher
Copy link
Copy Markdown
Contributor Author

Rebasing on top of #300

@yvaucher yvaucher merged commit 9b47f3a into camptocamp:release-4.5.X Feb 5, 2025
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.

2 participants