admin/pin: Add commands to pin booted, pending and rollback deployments
authorEric Curtin <ecurtin@redhat.com>
Wed, 24 Jan 2024 16:23:51 +0000 (16:23 +0000)
committerEric Curtin <ecurtin@redhat.com>
Mon, 29 Jan 2024 11:44:20 +0000 (11:44 +0000)
commitcda5103abeb7dbb5216060d0dbad365b42582b48
tree65ff6f43262a2670717174e130340552df59f5b0
parent79cb18bdd6b1c9cddd7e5773954c74b6f713d93c
admin/pin: Add commands to pin booted, pending and rollback deployments

Add new commands to pin the current, staged and previous deployment for
use in automation and scripting. Right now, it's difficult to pin the
current deployment without needing to look into the output of some other
tooling (like rpm-ostree) to get the index of each deployment. This
index also is not consistent - the current deployment could be 0 when
you first boot the system then 1 shortly after. This change makes it
easy to pin the current or future deployment.

Co-authored-by: Robert Sturla <robertsturla@outlook.com>
Signed-off-by: Eric Curtin <ecurtin@redhat.com>
man/ostree-admin-pin.xml
src/ostree/ot-admin-builtin-pin.c
src/ostree/ot-builtin-admin.c