[Refactor:Developer] Refactor migrator setup from install#11896
Conversation
…e installation process
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #11896 +/- ##
=========================================
Coverage 21.45% 21.45%
Complexity 9896 9896
=========================================
Files 268 268
Lines 36967 36967
Branches 495 495
=========================================
Hits 7933 7933
Misses 28543 28543
Partials 491 491
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
|
poorly named. this is not setup or installation of the database. this is migration/maintenance/update of the database. |
…r improved migration handling
jeffrey-cordero
left a comment
There was a problem hiding this comment.
Refactoring the migration process into a separate script looks well-implemented, and this is helpful as we continue to reduce the size of the large install script.
|
@lavalleeale |
bmcutler
left a comment
There was a problem hiding this comment.
looks ok except to make sure we don't attempt to run this on a worker.
|
I'm having trouble figuring out how to test the functionality. The code looks good and functional as far as I can see, but testing it on a worker machine is hard, given that workers generate and workers up do not seem to work whatsoever on this development branch. |
There was a problem hiding this comment.
I was able to verify that workers would not run this script if the install script is run and I was also able to verify that the script works on a vagrant up with a migration and without. I also tested the functionality of the migrator script and it is still working as well.
Why is this Change Important & Necessary?
Modularizing submitty_install is important because it will make it easier to manage which installation steps are run. The next steps will be to refactor the longer steps out of install_site.sh to allow them to be run separately when a developer is only working on one part of the site at a time.
What is the New Behavior?
The database migration and superuser checks are split into a new file. This will allow them to be run separately if desired as an example of the utility of refactoring the globals into
get_globals.sh.What steps should a reviewer take to reproduce or test the bug or new feature?
Automated Testing & Documentation
Other information