Today I installed Drupal 8 Backup Db module. Most of us have depended on Backup Migrate in d7; in its absense for d8 I found backup_db. This module required that I install Composer Manager module and initialize it. "$ php scripts/init.php"
Composer Manager reads composer.json files from each added module and coordinates requirements from all modules by rewriting your project's root composer.json file with correct versions. After each module addition, an execution of 'composer drupal-update' will keep everything in sync.
The steps are
- Install the Composer Manager module
- Run the module's init.php script on the command line. This does the initial consolidation of composer.json files
- Run 'composer drupal-update'
Afterwords, when adding additional modules
- Download the module
- Run 'composer drupal-update' in your project's root directory
- Enable the module
What a dream way to keep things in sync.
I also found a very interesting discussion on whether to commit /vendor dependencies to a git repository. The recommendation is, on a project with several developers, to have each manage vendor packages with composer and also run composer on the build machine. Since I am working solo on my project, I opted to use my local dev machine as a build environment and commit vendor packages to git to pull to production. I added .gitignore rules
With Backup DB module, backups can be done either as a Download or saved to a Local location. For either, it is necessary to have a private file path set. This is done in settings.php, not in the Files Config page as before.