Created
April 21, 2009 21:45
-
-
Save camwest/99409 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| desc "Push Content from Staging to Production." | |
| task :content_to_production, :roles => :db, :only => { :primary => true } do | |
| backup_name | |
| on_rollback { run "rm -f #{backup_file}" } | |
| run "mysqldump --add-drop-table -h #{staging_dbhost} -u #{dbuser} -p#{dbpass} #{staging_database} asset_directories assets authors chapter_overviews content_types contents cue_points mime_types multiple_choices nominal_role_infos nominal_roles overviews progress_tests question_options roles training_materials videos > #{backup_file}" | |
| run "mysql -u #{dbuser} -p#{dbpass} -h #{production_dbhost} #{production_database} < #{backup_file}" | |
| run "rm -f #{backup_file}" | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment