diff options
author | Tiago Gomes <tiago.gomes@codethink.co.uk> | 2013-06-15 15:48:01 +0000 |
---|---|---|
committer | Tiago Gomes <tiago.gomes@codethink.co.uk> | 2013-06-17 01:36:32 +0000 |
commit | 96402e53fd93cdd5f4005146e63bfc7d26903678 (patch) | |
tree | 137efa0aa9e619dc139e72ce5cf15af01f9c83de /morphlib/exts | |
parent | 1a83aa90877ee3dab7bfdd52df411d085f346592 (diff) | |
download | morph-96402e53fd93cdd5f4005146e63bfc7d26903678.tar.gz |
Run the merge mode of baserock-system-config-sync when upgrading running systems.
Diffstat (limited to 'morphlib/exts')
-rwxr-xr-x | morphlib/exts/ssh-rsync.write | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/morphlib/exts/ssh-rsync.write b/morphlib/exts/ssh-rsync.write index b8d30e22..9697e21b 100755 --- a/morphlib/exts/ssh-rsync.write +++ b/morphlib/exts/ssh-rsync.write @@ -71,6 +71,15 @@ class SshRsyncWriteExtension(morphlib.writeexts.WriteExtension): cliapp.ssh_runcmd(location, ['btrfs', 'subvolume', 'snapshot', orig_dir, run_dir]) + self.status(msg='Updating system configuration') + bscs_loc = os.path.join(run_dir, 'usr', 'bin', + 'baserock-system-config-sync') + try: + cliapp.ssh_runcmd(location, ['sh', bscs_loc, 'merge', + version_label]) + except: + self.status(msg='Updating system configuration failed') + self.install_remote_kernel(location, version_root, temp_root) default_path = os.path.join(remote_mnt, 'systems', 'default') if self.bootloader_is_wanted(): |