Skip to content

Commit

Permalink
libostree/deploy: create composefs image even if maybe
Browse files Browse the repository at this point in the history
Currently, we only create a composefs image if the enablement level is
`true`. But ISTM there's no reason we shouldn't lower the threshold to
`maybe` instead.

This makes it slightly less awkward to ratchet in composefs. Without
this, it's hard to have new nodes use composefs while still allowing
old nodes with ancient libostree to upgrade to the same image (without
composefs).
  • Loading branch information
jlebon committed Dec 11, 2024
1 parent ab8a7f7 commit debd2f4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/libostree/ostree-sysroot-deploy.c
Original file line number Diff line number Diff line change
Expand Up @@ -667,7 +667,7 @@ checkout_deployment_tree (OstreeSysroot *sysroot, OstreeRepo *repo, OstreeDeploy
g_debug ("composefs enabled by config: %d repo: %d", composefs_enabled, repo->composefs_wanted);
if (repo->composefs_wanted == OT_TRISTATE_YES)
composefs_enabled = repo->composefs_wanted;
if (composefs_enabled == OT_TRISTATE_YES)
if (composefs_enabled != OT_TRISTATE_NO)
{
composefs_start_time = g_get_monotonic_time ();
// TODO: Clean up our mess around composefs/fsverity...we have duplication
Expand Down
2 changes: 1 addition & 1 deletion tests/test-admin-deploy-composefs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ cd osdata
mkdir -p usr/lib/ostree
cat > usr/lib/ostree/prepare-root.conf << 'EOF'
[composefs]
enabled=true
enabled=maybe
EOF
${CMD_PREFIX} ostree --repo=${test_tmpdir}/testos-repo commit --add-metadata-string version=1.composefs -b testos/buildmain/x86_64-runtime
cd -
Expand Down

0 comments on commit debd2f4

Please sign in to comment.