...
- log in to victoria02
- grab the new scripts from github
- cd ~
- git clone git@github.com:cul-it/drupal-site-moves.git
- cd ~/drupal-site-moves
- git pull
- ./pull_from_production.sh <production site name> <test site name>
- you are prompted for your password
- you are asked to confirm the site move
- you are asked to inform the site users that you are working on the site on the test server
- put up the 'Site Under Maintenance' block
- script continues on without requiring any input from you
- backs up the database
- moves the site files to the target server
- installs the backed up database on the target server
- done
| Panel |
|---|
|
Log on to the production Drupal site and configure the 'Site under maintenance' block- Under 'Page specific visibility settings' select 'Show on every page except the listed pages.'
Make a backup of the production site to the Manual Backups Directory (using Backup and Migrate module)Log on to the test Drupal site- Drupal 6: http://$productiondomain/admin/content/backup_migrate/export
- Drupal 7: http://$productiondomain/admin/config/system/backup_migrate
Put the test site into maintenancemodemodego to victoria02 and cd /libweb/sites/[your site name]/make- Drupal 6: http://$testdomain/admin/settings/site-maintenance
- Drupal 7: http://$testdomain/admin/config/development/maintenance
- go to victoria02 and cd /libweb/sites/[your site name]/make
Determine what machine the production site is onLog on to the test Drupal site- victoria03 - www.library.cornell.edu, beta.library.cornell.edu
- sudo update_test_from_victoria03.sh [your production site domain] [your test site domain]
- victoria02 - all the others
- sudo update_test_from_production.sh [your production site domain] [your test site domain]
- the script will ask you if you completed each of the steps above and give you all the real paths to the pages you need to use
- the script moves the site with rsync
- victoria03 - www.library.cornell.edu, beta.library.cornell.edu
Restore the latest backuptake the testDrupal sitesite out of maintenance modeRestore the latest backup- Drupal 6: http://$testdomain/admin/content/backup_migrate/destination/list/files/manual
- Drupal 7: http://$testdomain/admin/config/system/backup_migrate/destination/list/files/manual
- click 'restore' next to the latest version of the file (hint: sort by file name!)
- take the test site out of maintenance mode
How to move from test to production
- log in to victoria01 or victoria03
- grab the new scripts from github
- cd ~
- git clone git@github.com:cul-it/drupal-site-moves.git
- cd ~/drupal-site-moves
- git pull
- ./pull_from_test.sh <test site name> <production site name>
- you are prompted for your password
- you are asked to confirm the site move
- you are asked to confirm again
- you can take down the 'Site Under Maintenance' block while the site is still on the test server
- script continues on without requiring any input from you
- backs up the database
- moves the site files to the target server
- installs the backed up database on the target server
- done
| Panel |
|---|
|
Log on to the test Drupal siteMake a backup of the test site to the Manual Backups Directory (using Backup and Migrate module)Log on to the production Drupal sitePut the production site into maintenance modeDetermine which machine the production site isononthe script will ask you if you've done each step and give you all the proper paths- victoria03 - www.library.cornell.edu, beta.library.cornell.edu
- ssh to the production machine victoria03 and cd /libweb/sites/[your site name]/make
- sudo update_victoria03_from_test.sh [your test domain] [your production domain]
- victoria01 - all the others
- ssh to the production machine victoria01 and cd /libweb/sites/[your site name]/make
- sudo update_production_from_test.sh [your test domain] [your production domain]
- victoria03 - www.library.cornell.edu, beta.library.cornell.edu
restore the latest backupconfigure the 'site under maintenance' blockUnder 'Page specific visibility settings' select 'Show on only the listed pages'