]> scripts.mit.edu Git - wizard.git/commitdiff
Revert redundant disable-rollback feature.
authorEdward Z. Yang <ezyang@mit.edu>
Mon, 25 Oct 2010 20:20:48 +0000 (21:20 +0100)
committerEdward Z. Yang <ezyang@mit.edu>
Mon, 25 Oct 2010 20:20:48 +0000 (21:20 +0100)
Signed-off-by: Edward Z. Yang <ezyang@mit.edu>
wizard/command/upgrade.py

index 91530c3a1341239b6c8ae25e18cc9ccb8b516b0a..223c260d113c284f952ef6608261cac01d0d9a20 100644 (file)
@@ -417,20 +417,12 @@ class Upgrade(object):
                     self.prod.upgrade(version_obj, self.options)
                     self.prod.verifyWeb()
                 except app.UpgradeFailure:
-                    if self.options.disable_rollback:
-                        logging.warning("Upgrade failed, rollback is disabled")
-                        logging.warning("You can manually rollback with: wizard restore top")
-                    else:
-                        logging.warning("Upgrade failed: rolling back")
-                        self.upgradeRollback(backup)
+                    logging.warning("Upgrade failed: rolling back")
+                    self.upgradeRollback(backup)
                     raise
                 except deploy.WebVerificationError as e:
-                    if self.options.disable_rollback:
-                        logging.warning("Web verification failed, rollback is disabled")
-                        logging.warning("You can manually rollback with: wizard restore top")
-                    else:
-                        logging.warning("Web verification failed: rolling back")
-                        self.upgradeRollback(backup)
+                    logging.warning("Web verification failed: rolling back")
+                    self.upgradeRollback(backup)
                     raise app.UpgradeVerificationFailure()
         # XXX: frob .htaccess to make site accessible
         #       to do this, check if .htaccess changed, first.  Upgrade
@@ -482,8 +474,6 @@ of the conflicted working tree to stdout, separated by a space."""
             default=False, help="Force running upgrade even if it's already at latest version.")
     parser.add_option("--skip-verification", dest="skip-verification", action="store_true",
             default=False, help="Skip running configuration and web verification checks.")
-    parser.add_option("--disable-rollback", dest="disable-rollback", action="store_true",
-            default=False, help="Don't automatically rollback the upgrade if the result fails to verify.")
     parser.add_option("--non-interactive", dest="non_interactive", action="store_true",
             default=False, help="Don't drop to shell in event of conflict.")
     parser.add_option("--rr-cache", dest="rr_cache", metavar="PATH",