summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Thursfield <sam.thursfield@codethink.co.uk>2014-03-04 11:49:02 +0000
committerSam Thursfield <sam.thursfield@codethink.co.uk>2014-03-04 13:17:06 +0000
commit976db9042d851de2c70e2719c32f611d68681209 (patch)
tree85a39a79f4a9d7a006d18a96b1a31722f3dfef5d
parent10f976692306986ca16fd05c123ae7107cbc0a17 (diff)
downloadmorph-976db9042d851de2c70e2719c32f611d68681209.tar.gz
deploy: Always set new system as default
-rwxr-xr-xmorphlib/exts/ssh-rsync.write5
1 files changed, 5 insertions, 0 deletions
diff --git a/morphlib/exts/ssh-rsync.write b/morphlib/exts/ssh-rsync.write
index 4961ee4d..8dc0fe35 100755
--- a/morphlib/exts/ssh-rsync.write
+++ b/morphlib/exts/ssh-rsync.write
@@ -93,6 +93,11 @@ class SshRsyncWriteExtension(morphlib.writeexts.WriteExtension):
cliapp.ssh_runcmd(location,
['env', 'BASEROCK_SYSTEM_CONFIG_SYNC='+system_config_sync,
system_version_manager, 'deploy', deployment])
+
+ self.status(msg='Setting %s as the new default system' %
+ version_label)
+ cliapp.ssh_runcmd(location,
+ [system_version_manager, 'set-default', version_label])
except Exception as e:
self.status(msg='Deployment failed')
ssh_runcmd_ignore_failure(