Colin Walters [Tue, 23 Jan 2024 02:05:44 +0000 (21:05 -0500)]
Merge pull request #3143 from yummypeng/main
deploy: Ignore sockets, fifos in /etc/<subdir> during merge
Yuanhong Peng [Mon, 22 Jan 2024 10:03:55 +0000 (18:03 +0800)]
deploy: Ignore sockets, fifos in /etc/<subdir> during merge
It's a followup of commit
e6a560b40797324aa8b90e7100c6d50bff91f14d.
We should also ignore sockets and fifos in the subdir of /etc.
Signed-off-by: Yuanhong Peng <yummypeng@linux.alibaba.com>
Colin Walters [Sun, 21 Jan 2024 16:00:20 +0000 (11:00 -0500)]
Merge pull request #3141 from cgwalters/release
Release 2024.1
Colin Walters [Fri, 19 Jan 2024 22:27:09 +0000 (17:27 -0500)]
configure: post-release version bump
Colin Walters [Fri, 19 Jan 2024 22:26:26 +0000 (17:26 -0500)]
Release 2024.1
Colin Walters [Thu, 11 Jan 2024 16:57:22 +0000 (11:57 -0500)]
Merge pull request #3135 from ericcurtin/aboot-documentation
doc: Add section about ostree and aboot
Colin Walters [Thu, 11 Jan 2024 16:56:44 +0000 (11:56 -0500)]
Merge pull request #3120 from jlebon/pr/state-overlays
Add concept of state overlays
Jonathan Lebon [Wed, 10 Jan 2024 18:17:06 +0000 (13:17 -0500)]
build(deps): bump libglnx from `
aff1eea` to `
b415d046`
Bumps libglnx from `
aff1eea` to `
b415d046`.
For https://gitlab.gnome.org/GNOME/libglnx/-/merge_requests/52.
Update submodule: libglnx
Jonathan Lebon [Thu, 14 Dec 2023 21:46:14 +0000 (16:46 -0500)]
Add concept of state overlays
In the OSTree model, executables go in `/usr`, state in `/var` and
configuration in `/etc`. Software that lives in `/opt` however messes
this up because it often mixes code *and* state, making it harder to
manage.
More generally, it's sometimes useful to have the OSTree commit contain
code under a certain path, but still allow that path to be writable by
software and the sysadmin at runtime (`/usr/local` is another instance).
Add the concept of state overlays. A state overlay is an overlayfs
mount whose upper directory, which contains unmanaged state, is carried
forward on top of a lower directory, containing OSTree-managed files.
In the example of `/usr/local`, OSTree commits can ship content there,
all while allowing users to e.g. add scripts in `/usr/local/bin` when
booted into that commit.
Some reconciliation logic is executed whenever the base is updated so
that newer files in the base are never shadowed by a copied up version
in the upper directory. This matches RPM semantics when upgrading
packages whose files may have been modified.
For ease of integration, this is exposed as a systemd template unit which
any downstream distro/user can enable. The instance name is the mountpath
in escaped systemd path notation (e.g.
`ostree-state-overlay@usr-local.service`).
See discussions in https://github.com/ostreedev/ostree/issues/3113 for
more details.
Jonathan Lebon [Tue, 9 Jan 2024 16:40:58 +0000 (11:40 -0500)]
Merge pull request #3136 from ericcurtin/pr-3134-feedback
Eric Curtin [Tue, 9 Jan 2024 15:23:47 +0000 (15:23 +0000)]
status: Rename query-booted to is-default
This is a tool to check if we are booted as default or not, just a
rename before it becomes widely used. We also shortened the '-h' output
for this.
Signed-off-by: Eric Curtin <ecurtin@redhat.com>
Colin Walters [Mon, 8 Jan 2024 18:14:50 +0000 (13:14 -0500)]
Merge pull request #3134 from ericcurtin/query-boot-real
status: Introduce tool to quickly check if we are booted as default
Colin Walters [Mon, 8 Jan 2024 12:38:53 +0000 (07:38 -0500)]
Merge pull request #3133 from cgwalters/boot-complete-rollback
systemd/ostree-boot-complete: Start earlier
Eric Curtin [Fri, 5 Jan 2024 18:18:22 +0000 (18:18 +0000)]
status: Fix --skip-signatures description
It was a copy-paste of another description, rather than it's own.
Signed-off-by: Eric Curtin <ecurtin@redhat.com>
Eric Curtin [Fri, 5 Jan 2024 17:08:43 +0000 (17:08 +0000)]
man: Add ostree admin status man page CLI options.
Document the various CLI options.
Signed-off-by: Eric Curtin <ecurtin@redhat.com>
Eric Curtin [Fri, 5 Jan 2024 15:49:39 +0000 (15:49 +0000)]
status: Introduce tool to quickly check if we are booted as default
Generally in ostree based systems you would expect to boot into
deployment 0, in rollback conditions triggered by greenboot-related
rollbacks this might not be the case. This is a tool to detect this.
Signed-off-by: Eric Curtin <ecurtin@redhat.com>
Eric Curtin [Fri, 5 Jan 2024 17:32:44 +0000 (17:32 +0000)]
doc: Add section about ostree and aboot
Android Bootloader is a standard of how Android devices should implement
their bootloaders, we also use it in CentOS Automotive Stream
Distribution for some ARM boards. Here is some documentation on how
ostree works with this.
Signed-off-by: Eric Curtin <ecurtin@redhat.com>
Colin Walters [Fri, 5 Jan 2024 17:22:57 +0000 (12:22 -0500)]
Merge pull request #3132 from ericcurtin/query-boot
status: Fix build without GPGME
Colin Walters [Fri, 5 Jan 2024 15:58:57 +0000 (10:58 -0500)]
systemd/ostree-boot-complete: Start earlier
Prep for changing this service to perform state computations
such as "is this boot the default, or did we get rolled back"
that can be used by higher level tools.
Colin Walters [Fri, 5 Jan 2024 15:57:16 +0000 (10:57 -0500)]
systemd/ostree-boot-complete: Add `ConditionKernelCommandLine=ostree`
In practice we don't enable this unit except via our generator,
but let's do this on general principle.
Eric Curtin [Fri, 5 Jan 2024 14:39:46 +0000 (14:39 +0000)]
status: Fix build without GPGME
If OSTREE_DISABLE_GPGME is not built in set remote to NULL.
The ostree_repo_signature_verify_commit_data path is irrelevant in the
no gpg case anyway. Having this set as NULL ensures an error gets
thrown early.
Signed-off-by: Eric Curtin <ecurtin@redhat.com>
Eric Curtin [Fri, 5 Jan 2024 14:28:47 +0000 (14:28 +0000)]
Merge pull request #3131 from cgwalters/status-use-remote
status: Pass correct remote name when verifying
Colin Walters [Thu, 4 Jan 2024 20:57:08 +0000 (15:57 -0500)]
Merge pull request #3130 from jlebon/pr/autoprune-aarch64-dtb
lib/deploy: Round to block size in early prune space check
Colin Walters [Thu, 4 Jan 2024 19:02:08 +0000 (14:02 -0500)]
status: Add an option to skip signature verification
Since it's really expensive in some cases.
Colin Walters [Thu, 4 Jan 2024 18:55:14 +0000 (13:55 -0500)]
status: Pass correct remote name when verifying
The default `ostree admin status` tries to do signature
verification, but doesn't error out if that fails.
However, an extremely longstanding bug here is that we passed
the "osname" aka stateroot instead of the remote name. This
happens to work for e.g. Fedora Silverblue today, where they
are the same. It doesn't work on FCOS (remote = fedora, stateroot = fedora-coreos).
Jonathan Lebon [Thu, 4 Jan 2024 16:14:40 +0000 (11:14 -0500)]
lib/deploy: Add safety margin in early prune space check
There are a few things the estimator doesn't account for, e.g. writing
the new BLS entries. Rather than trying to perfect it (since I think we
should change approach entirely -- see previous commit message), just
add a 1M margin to the space check.
Jonathan Lebon [Thu, 4 Jan 2024 16:14:39 +0000 (11:14 -0500)]
lib/deploy: Round to block size in early prune space check
When we estimate how much space a new bootcsum dir will use, we
weren't accounting for the space overhead from files not using the
last filesystem block completely. This doesn't matter much if counting
a few files, but e.g. on FCOS aarch64, we include lots of small
devicetree blobs in the bootfs. That loss can add up to enough for the
`fallocate()` check to pass but copying still hitting `ENOSPC` later on.
I think a better fix here is to change approach entirely and instead
refactor `install_deployment_kernel()` so that we can call just the
copying bits of it as part of the early prune logic. We'll get a more
accurate assessment and it's not lost work since we won't need to
recopy later on. Also this would not require having to keep in sync the
estimator and the install bits.
That said, this is blocking FCOS releases, so I went with a more tactical
fix for now.
Fixes: https://github.com/coreos/fedora-coreos-tracker/issues/1637
Colin Walters [Thu, 4 Jan 2024 15:40:09 +0000 (10:40 -0500)]
Merge pull request #3129 from cgwalters/fix-unlock-composefs-compat
prepare-root: Fix composefs + ostree admin unlock --hotfix compat
Eric Curtin [Thu, 4 Jan 2024 12:05:02 +0000 (12:05 +0000)]
Merge pull request #3128 from cgwalters/hotfix-composefs
switchroot: use shared constant for unlock --hotfix
Colin Walters [Wed, 3 Jan 2024 18:05:15 +0000 (13:05 -0500)]
switchroot: use shared constant for unlock --hotfix
So it's easier to link the two bits of code.
Colin Walters [Wed, 3 Jan 2024 19:01:38 +0000 (14:01 -0500)]
prepare-root: Fix composefs + ostree admin unlock --hotfix compat
There's a test case for `ostree admin unlock --hotfix` that
runs in FCOS, not here; it breaks when enabling composefs.
The reason is because the composefs is mounted readonly, and
we tried to remount it writable. Instead of trying to remount
the rootfs writable at this point forcibly, honor the
*real* sysroot readonly state flag from the underlying FS before
we mounted the composefs.
Note that in FCOS derivatives we always have the root mounted
writable via `rw` on the kernel cmdline and this is the default
general expectation now with ostree usage.
Colin Walters [Tue, 2 Jan 2024 20:53:01 +0000 (15:53 -0500)]
Merge pull request #3127 from cgwalters/composefs-doc-toplevel-chattr
docs/composefs: Add note about toplevel dirs
Joseph Marrero Corchado [Tue, 2 Jan 2024 20:49:24 +0000 (15:49 -0500)]
Merge pull request #3119 from cgwalters/zipl-fix-nul-term
zipl: A few fixes
Colin Walters [Tue, 2 Jan 2024 20:16:47 +0000 (15:16 -0500)]
docs/composefs: Add note about toplevel dirs
Just thinking about trying to land this, I think some people
may hit this one.
Colin Walters [Sat, 30 Dec 2023 15:55:09 +0000 (16:55 +0100)]
Merge pull request #3125 from ericcurtin/explicit-sysroot-rw-ro-log
switchroot: Be explicit about what could cause /sysroot to be ro
Eric Curtin [Thu, 21 Dec 2023 17:11:55 +0000 (17:11 +0000)]
switchroot: Be explicit about what could cause /sysroot to be ro
If you don't have rw in the kernel cmdline or have ro in it, often you
hit this issue. This is just to be really explicit about that in the
error messages so people can check.
Signed-off-by: Eric Curtin <ecurtin@redhat.com>
Eric Curtin [Wed, 20 Dec 2023 12:48:53 +0000 (12:48 +0000)]
Merge pull request #3124 from cgwalters/rust-features
rust: Add missing feature versions
Colin Walters [Wed, 20 Dec 2023 12:22:21 +0000 (07:22 -0500)]
Merge pull request #3123 from cgwalters/deploy-log-space
deploy: Log calculated needed space
Colin Walters [Tue, 19 Dec 2023 20:00:05 +0000 (15:00 -0500)]
deploy: Log calculated needed space
To aid debugging issues like https://github.com/coreos/fedora-coreos-tracker/issues/1637
If we're hitting this path where we think we have enough space,
let's log what we calculated here to aid in diagnosing why we
may later fail with ENOSPC.
Colin Walters [Wed, 20 Dec 2023 02:01:21 +0000 (21:01 -0500)]
rust: Add missing feature versions
- We missed 2022_2, which specifically includes
https://docs.rs/ostree/latest/ostree/static.PATH_BOOTED.html
and I was really confused why that was missing
- Add more recent upstream versions too
Colin Walters [Mon, 18 Dec 2023 14:22:13 +0000 (09:22 -0500)]
Merge pull request #3121 from fwilhe/patch-1
Link to gardenlinux/ostree-image-builder in README
Florian Wilhelm [Mon, 18 Dec 2023 13:12:45 +0000 (14:12 +0100)]
Link to gardenlinux/ostree-image-builder in README
This repo is the outcome of a PoC on how an existing
debian-based distro could be adapted to be used with OSTree.
Eric Curtin [Thu, 14 Dec 2023 22:05:10 +0000 (22:05 +0000)]
Merge pull request #3116 from jmarrero/bootloader-doc
doc: Add section about ostree and bootloaders
Colin Walters [Thu, 14 Dec 2023 13:06:57 +0000 (08:06 -0500)]
zipl: Convert to a data input stream
This high level reader API avoids all the bugs that were
found in previous patches.
Colin Walters [Thu, 14 Dec 2023 13:03:01 +0000 (08:03 -0500)]
zipl: NUL terminate buffer we're searching
Found by a static analyzer.
Colin Walters [Thu, 14 Dec 2023 13:00:38 +0000 (08:00 -0500)]
zipl: Fix error handling for read
The return value is not errno.
Colin Walters [Thu, 14 Dec 2023 12:57:43 +0000 (07:57 -0500)]
zipl: Use O_CLOEXEC
On general principle.
Joseph Marrero [Fri, 8 Dec 2023 15:44:01 +0000 (10:44 -0500)]
doc: Add section about ostree and bootloaders
Joseph Marrero Corchado [Mon, 11 Dec 2023 19:23:33 +0000 (14:23 -0500)]
Merge pull request #3117 from cgwalters/doc-root-transient
Doc root transient
Colin Walters [Fri, 8 Dec 2023 19:01:13 +0000 (14:01 -0500)]
docs: Add `var.md`
This one overlaps a bit with some other sections...the docs
need a bigger rework, but this is better than we had before.
Colin Walters [Fri, 8 Dec 2023 18:58:42 +0000 (13:58 -0500)]
man: Document `root.transient`
This one warrants some explanation.
Eric Curtin [Fri, 8 Dec 2023 14:02:56 +0000 (14:02 +0000)]
Merge pull request #3114 from cgwalters/root-ovl
prepare-root: Add support for root.transient
Colin Walters [Thu, 7 Dec 2023 15:21:05 +0000 (10:21 -0500)]
prepare-root: Add support for root.transient
Closes: https://github.com/ostreedev/ostree/issues/3113
It'd greatly improve compatibility with things like RPMs that install
in `/opt` if we supported a full "original docker" style model where
`/` is a transient overlayfs. We'd still keep our semantics for `/etc`
and `/var` by default, but e.g. we'd stop recommending
`/opt` :arrow_right: `/var/opt`, in this model,
so `/opt` would be on the overlayfs.
Note this all aligns with composefs, where we'd actually be making
`/` a *read-only* overlayfs by default; it'd be really nice of course
to *implement* this by just making the composefs overlayfs writable,
but I am not sure we can hard require composefs for this right now.
So this change adds support for `root.transient = true`
in `/usr/lib/ostree/prepare-root.conf`.
The major downside is that people could be surprised if files they
write to e.g. `/opt` don't persist across upgrades. But, that's
already again how it works since Docker started.
Note as part of the implementation of this, we need to add a whole
new "backing" directory distinct from the deployment directories.
(Tangentially related to this, it's tempting to switch to always
using a *read-only* overlay mount by default.
Colin Walters [Thu, 7 Dec 2023 15:03:04 +0000 (10:03 -0500)]
prepare-root: Add an autofree
This doesn't matter at all, but I just noticed this while working
on the code.
Colin Walters [Thu, 7 Dec 2023 14:58:59 +0000 (09:58 -0500)]
sysroot: Drop unused prototype
This function doesn't exist anymore.
Colin Walters [Thu, 7 Dec 2023 14:48:22 +0000 (09:48 -0500)]
Merge pull request #3112 from leonheldattoradex/main
Update Torizon information
Leonardo Held [Thu, 7 Dec 2023 13:08:16 +0000 (10:08 -0300)]
Update Torizon information
TorizonCore became Torizon OS and Torizon OTA is now Torizon Cloud.
Signed-off-by: Leonardo Held <leonardo.held@toradex.com>
Joseph Marrero Corchado [Wed, 6 Dec 2023 02:52:21 +0000 (21:52 -0500)]
Merge pull request #3111 from cgwalters/release
Release 2023.8
Colin Walters [Mon, 4 Dec 2023 23:29:13 +0000 (18:29 -0500)]
configure: post-release version bump
Colin Walters [Mon, 4 Dec 2023 23:28:32 +0000 (18:28 -0500)]
Release 2023.8
Colin Walters [Tue, 5 Dec 2023 18:36:00 +0000 (13:36 -0500)]
Merge pull request #3106 from cgwalters/commit-reflink
commit: Try reflinks for local commits by default
Colin Walters [Sat, 2 Dec 2023 20:48:12 +0000 (15:48 -0500)]
commit: Try reflinks for local commits by default
I think we originally used to do this, but at some point in a
code refactoring, this optimization got lost.
It's a quite important optimization for the case of writing content
generated by an external system into an ostree repository.
Joseph Marrero Corchado [Mon, 4 Dec 2023 23:22:50 +0000 (18:22 -0500)]
Merge pull request #3105 from cgwalters/sysroot-borrow-fd
sysroot: Add a method to borrow sysroot fd
Colin Walters [Mon, 4 Dec 2023 18:14:07 +0000 (13:14 -0500)]
Merge pull request #3107 from cgwalters/drop-userxattr-test
tests: Drop bare-user on tmpfs negative test
Colin Walters [Sun, 3 Dec 2023 14:32:36 +0000 (09:32 -0500)]
tests: Drop bare-user on tmpfs negative test
As of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=
2daf18a7884dc03d5164ab9c7dc3f2ea70638469
the restriction is lifted, FINALLY.
Colin Walters [Fri, 1 Dec 2023 21:21:34 +0000 (16:21 -0500)]
Merge pull request #3104 from cgwalters/s390x-target
bootloader/zipl: Run in target deployment as container if needed
Colin Walters [Thu, 30 Nov 2023 23:16:33 +0000 (18:16 -0500)]
bootloader/zipl: Run in target deployment as container if needed
xref https://issues.redhat.com/browse/MGMT-16303
Basically the OCP Assisted installer has now grown code
to try to do OS updates offline post-install, and this means
we need to handle the case of running zipl from the target
root.
Colin Walters [Fri, 1 Dec 2023 20:05:40 +0000 (15:05 -0500)]
sysroot: Expose deployment runner outside of selinux
We will use it in e.g. s390x zipl backend.
Joseph Marrero Corchado [Fri, 1 Dec 2023 19:46:39 +0000 (14:46 -0500)]
Merge pull request #3103 from cgwalters/tmpfiles-factory-var
tmpfiles: Copy `/usr/share/factory/var` to `/var`
Colin Walters [Fri, 1 Dec 2023 19:35:41 +0000 (14:35 -0500)]
sysroot: Add a method to borrow sysroot fd
For the same reason we have this method on `Repo`.
Colin Walters [Fri, 1 Dec 2023 13:14:15 +0000 (08:14 -0500)]
sysroot: Support specifying bwrap arguments
Prep for use with zipl.
Colin Walters [Thu, 30 Nov 2023 16:12:55 +0000 (11:12 -0500)]
sysroot: Expose deployment container executor internally
Prep for using this for zipl.
Colin Walters [Thu, 30 Nov 2023 20:33:42 +0000 (15:33 -0500)]
tmpfiles: Copy `/usr/share/factory/var` to `/var`
This is a pattern we want to encourage. It's honestly just
way simpler than what rpm-ostree is doing today in auto-synthesizing
individual tmpfiles.d snippets.
Jonathan Lebon [Thu, 30 Nov 2023 22:34:29 +0000 (17:34 -0500)]
Merge pull request #3102 from cgwalters/deploy-cleanup-run
Colin Walters [Thu, 30 Nov 2023 15:26:32 +0000 (10:26 -0500)]
sysroot/deploy: Drop unnecessary g_ptr_array_free
We can just reference the pdata, and autoptr the array.
Colin Walters [Thu, 30 Nov 2023 15:25:12 +0000 (10:25 -0500)]
deploy: Use NULL terminated strv
This makes the code simpler and avoids the need
to keep the string array and length in sync. Prep for
further callers.
Jonathan Lebon [Wed, 29 Nov 2023 19:10:22 +0000 (14:10 -0500)]
Merge pull request #3100 from cgwalters/misc-finalization
Colin Walters [Mon, 27 Nov 2023 20:34:20 +0000 (15:34 -0500)]
tests: Add a dedicated finalization test
This one covers `admin lock-finalization --unlock`.
Joseph Marrero Corchado [Tue, 28 Nov 2023 02:28:43 +0000 (21:28 -0500)]
Merge pull request #3101 from cgwalters/drop-redundant-includes
main: Drop some redundant includes of `ot-main.h`
Colin Walters [Tue, 28 Nov 2023 01:08:43 +0000 (20:08 -0500)]
main: Drop some redundant includes of `ot-main.h`
When backporting a patch recently we hit a non-obvious
dependency on another fix for `ot-main.h` includes. Clean
this up a bit by dropping the redundant includes.
Colin Walters [Mon, 27 Nov 2023 18:50:07 +0000 (13:50 -0500)]
man: Two finalization fixes
From PR review.
Colin Walters [Mon, 27 Nov 2023 18:48:59 +0000 (13:48 -0500)]
Merge pull request #3090 from cgwalters/stabilize-locking
sysroot: Stabilize deployment finalization, add API
Colin Walters [Wed, 8 Nov 2023 22:19:19 +0000 (17:19 -0500)]
sysroot: Stabilize deployment finalization, add API and CLI
It's about time we do this; deployment finalization locking
is a useful feature. An absolutely key thing here is that
we've slowly been moving towards the deployments as the primary
"source of truth".
Specifically in bootc for example, we will GC container images
not referenced by a deployment.
This is then neecessary to support a "pull but don't apply automatically" model.
This stabilizes the existing `ostree admin deploy --lock-finalization`
CLI, and adds a new `ostree admin unlock-finalization`.
We still check the old lock file path, but there's a new boolean
value as part of the staged deployment data which is intended
to be the source of truth in the future. At some point then we
can drop the rpm-ostree lockfile handling.
Closes: https://github.com/ostreedev/ostree/issues/3025
Colin Walters [Mon, 27 Nov 2023 15:54:18 +0000 (10:54 -0500)]
status: Add error prefix for gpg verification
It's helpful to see which deployment has an error.
Colin Walters [Mon, 27 Nov 2023 15:59:04 +0000 (10:59 -0500)]
tests: Turn off gpg verification for dev builds
Right now `ostree admin status` errors out in this case, but
`rpm-ostree status` doesn't. The former behavior is probably
more of a bug, work around it for now.
Colin Walters [Mon, 27 Nov 2023 13:39:35 +0000 (08:39 -0500)]
Merge pull request #3099 from markmc/man-sysroot-readonly
man: improve sysroot.readonly docs
Mark McLoughlin [Fri, 24 Nov 2023 14:27:11 +0000 (14:27 +0000)]
man: improve sysroot.readonly docs
The explanation of sysroot.readonly is a little confusing - we say
that "everything else is mounted read-only" but it's perhaps clearer
to say /sysroot is mounted read-only.
Also note that read-only is the default with composefs.
Finally, document the option in ostree.repo-config even though it is
now considered legacy - as of commit
22b8e4f9 (#2930) - it is still
commonly seen in repo configs, so users will look to understand
what it means.
Jonathan Lebon [Tue, 21 Nov 2023 22:18:17 +0000 (17:18 -0500)]
Merge pull request #3098 from jlebon/pr/abort-concurrent
Jonathan Lebon [Tue, 21 Nov 2023 20:31:38 +0000 (15:31 -0500)]
ci: cancel previous build on PR update
This is an easy way to save CI resources; when a PR is updated, abort
any previous build for that PR to focus on testing the latest push.
Colin Walters [Tue, 21 Nov 2023 13:34:32 +0000 (08:34 -0500)]
Merge pull request #3097 from cgwalters/symbol-cleanups
Symbol cleanups
Colin Walters [Mon, 20 Nov 2023 14:47:40 +0000 (09:47 -0500)]
lib: Don't hardcode year in sample symver section
The 2021 was misleading.
Colin Walters [Mon, 20 Nov 2023 14:45:39 +0000 (09:45 -0500)]
devel: Fix symbol versioning number
The .11 was wrong.
Colin Walters [Tue, 14 Nov 2023 22:40:08 +0000 (17:40 -0500)]
Merge pull request #3095 from alexlarsson/fix-post-copy-symlinks
Fix admin post-copy handling of symlinks
Alexander Larsson [Tue, 14 Nov 2023 21:36:58 +0000 (22:36 +0100)]
Fix admin post-copy handling of symlinks
The code to enable fs-verity on an object file was failing with ENOENT
for symlink objects.
Colin Walters [Tue, 14 Nov 2023 14:01:41 +0000 (09:01 -0500)]
Merge pull request #3094 from alexlarsson/admin-deploy-post-copy
Add `ostree admin post-copy` command
Alexander Larsson [Mon, 13 Nov 2023 16:33:57 +0000 (17:33 +0100)]
Add `ostree admin post-copy` command
This command will apply fs-verity on all objects that need it and
needs to be called when an ostree deployment has been copied on a
file-by-file basis, which would loose information such as fs-verity.
This is needed by osbuild which works by creating the final image in a
rootfs, and then separately copying that rootfs file-by-file to a
loopback mounted filesystem image.
Eric Curtin [Fri, 10 Nov 2023 16:39:13 +0000 (16:39 +0000)]
Merge pull request #3091 from cgwalters/fix-soup3
build-sys: Enable libsoup3 by default if installed
Colin Walters [Fri, 10 Nov 2023 01:53:52 +0000 (20:53 -0500)]
unlock: Don't pass options again to overlayfs
There seems to be a tricky regression here with the util-linux
support for the new mount API, plus overlays support for it.
```
[2023-11-09T21:05:30.633Z] Nov 09 21:05:26 qemu0 kola-runext-unlock-transient.sh[2108]: + unshare -m -- /bin/sh -c 'mount -o remount,rw /usr && echo hello from transient unlock >/usr/share/writable-usr-test'
[2023-11-09T21:05:30.633Z] Nov 09 21:05:26 qemu0 kola-runext-unlock-transient.sh[2148]: mount: /usr: mount point not mounted or bad option.
[2023-11-09T21:05:30.633Z] Nov 09 21:05:26 qemu0 kola-runext-unlock-transient.sh[2148]: dmesg(1) may have more information after failed mount system call.
```
OK this seems related to the new mount API support in util-linux and overlayfs. From a strace:
```
2095 open_tree(AT_FDCWD, "/usr", OPEN_TREE_CLOEXEC) = 3
2095 mount_setattr(-1, NULL, 0, NULL, 0) = -1 EINVAL (Invalid argument)
...
2095 fspick(3, "", FSPICK_NO_AUTOMOUNT|FSPICK_EMPTY_PATH) = 4
2095 fsconfig(4, FSCONFIG_SET_FLAG, "seclabel", NULL, 0) = 0
2095 fsconfig(4, FSCONFIG_SET_STRING, "lowerdir", "usr", 0) = -1 EINVAL (Invalid argument)
```
I think the core problem here is it's trying to reconfigure the mount with existing options,
but in the new mount namespace we can't see the lowerdir.
Here we really really just want to remount writable. Telling
util-linux to not pass existing options fixes it.
Colin Walters [Thu, 9 Nov 2023 20:21:47 +0000 (15:21 -0500)]
Merge pull request #3093 from cgwalters/rust-alias-stateroot
rust: Add a `stateroot()` alias in the Rust bindings
Colin Walters [Thu, 9 Nov 2023 19:08:41 +0000 (14:08 -0500)]
tests: Work around systemd regression for boot id parsing
cc https://github.com/systemd/systemd/issues/29275