diff options
author | Colin Walters <walters@verbum.org> | 2018-04-12 12:40:08 -0400 |
---|---|---|
committer | Atomic Bot <atomic-devel@projectatomic.io> | 2018-04-18 18:59:15 +0000 |
commit | 16d3359bf8827f6a6d70aa313c6e7f16a4f2e277 (patch) | |
tree | 3dfdec5cd93ae88865e7431362be4336cd987b46 /src/ostree/ot-admin-builtin-status.c | |
parent | 09dc2a87724111e83249b42dd4c4faa5dd2c2840 (diff) | |
download | ostree-16d3359bf8827f6a6d70aa313c6e7f16a4f2e277.tar.gz |
lib/sysroot: Move staged into deployment list, rework handling
Followup to: https://github.com/ostreedev/ostree/pull/1503
After starting some more work on on this in rpm-ostree, it is
actually simpler if the staged deployment just shows up in the list.
It's effectively opt-in today; down the line we may make it the default,
but I worry about breaking things that e.g. assume they can mutate
the deployment before rebooting and have `/etc` already merged.
There's not that many things in libostree that iterate over the deployment
list. The biggest change here is around the
`ostree_sysroot_write_deployments_with_options` API. I initially
tried hard to support a use case like "push a rollback" while retaining
the staged deployment, but everything gets very messy because that
function truly is operating on the bootloader list.
For now what I settled on is to just discard the staged deployment;
down the line we can enhance things.
Where we then have some new gymnastics is around implementing
the finalization; we need to go to some effort to pull the staged
deployment out of the list and mark it as unstaged, and then pass
it down to `write_deployments()`.
Closes: #1539
Approved by: jlebon
Diffstat (limited to 'src/ostree/ot-admin-builtin-status.c')
-rw-r--r-- | src/ostree/ot-admin-builtin-status.c | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/src/ostree/ot-admin-builtin-status.c b/src/ostree/ot-admin-builtin-status.c index 55be6994..ca165f45 100644 --- a/src/ostree/ot-admin-builtin-status.c +++ b/src/ostree/ot-admin-builtin-status.c @@ -201,16 +201,6 @@ ot_admin_builtin_status (int argc, char **argv, OstreeCommandInvocation *invocat } else { - OstreeDeployment *staged = ostree_sysroot_get_staged_deployment (sysroot); - if (staged) - { - if (!deployment_print_status (sysroot, repo, staged, - FALSE, FALSE, FALSE, - cancellable, - error)) - return FALSE; - } - for (guint i = 0; i < deployments->len; i++) { OstreeDeployment *deployment = deployments->pdata[i]; |