-
Notifications
You must be signed in to change notification settings - Fork 80
Switch /etc to use confext in mutable mode #3555
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
pothos
wants to merge
6
commits into
main
Choose a base branch
from
kai/default-confext
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
f05a9fa
acct-group/clock: New package
pothos b7c413a
sys-apps/systemd: Sync with Gentoo to update to 258.2
pothos d0b0985
build_sysext: Set daemon reload metadata field
pothos 77f278a
Revert "Revert PR #3534 "sysext: Add OS-dependent sysext compression""
pothos aef9fd6
Use systemd-confext instead of custom /etc overlay mount
pothos 6025111
DROP: Use mantle kola PR ref
pothos File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| - OS-dependent sysexts (e.g., docker-flatcar, containerd-flatcar) are now cryptographically signed using dm-verity roothash signatures. This enables stricter sysext policies via systemd-sysext and provides a foundation for verifying user-provided extensions in future releases. The format changed from squashfs to erofs-based Discoverable Disk Images (DDI). ([scripts#3162](https://github.com/flatcar/scripts/pull/3162)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,2 @@ | ||
| - Switched `/etc/` from a custom overlayfs for A/B updates to using a systemd-confext extension providing the default contents by using systemd-confext in the mutable mode where `/etc/` gets used as upperdir [scripts#3555](https://github.com/flatcar/scripts/pull/3555) | ||
| - Moved systemd-sysext image mounting into the initrd, so that system extensions can better define the behavior of the final system at boot without workarounds to apply settings late at boot. This means `.wants` symlinks for systemd units work as expected now and, therefore, we dropped the `ensure-sysext.service` workaround. We still recommend extensions to keep their workarounds, e.g., using `.upholds` instead of `.wants`, to better support live reloading. A skipping logic prevents an extension refresh late at boot but only if no changes were found. For extensions that are not stored on a custom filesystem, such as a separate `/var` partition, the new extension mounting from the initrd won't be able to load them early but they will be picked up late at boot through the extension refresh. This is another case where it's good if extensions keep workarounds for late loading. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| - systemd (258.2) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1 +1 @@ | ||
| ghcr.io/flatcar/mantle:git-bed79eb716792cbd6f79301f515bafcdb59ee93d | ||
| ghcr.io/flatcar/mantle:pr-720 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
...-patches/sys-apps/systemd/0001-vpick-Don-t-use-openat-directly-but-resolve-symlinks.patch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,33 @@ | ||
| From 6f4b065b626edd8a06ff0c8028173e060b5e444b Mon Sep 17 00:00:00 2001 | ||
| From: Kai Lueke <[email protected]> | ||
| Date: Thu, 20 Nov 2025 23:43:55 +0900 | ||
| Subject: [PATCH 03/10] vpick: Don't use openat directly but resolve symlinks | ||
| in given root | ||
|
|
||
| With systemd-sysext --root= all symlinks should be followed relative to | ||
| the given root and direct openat usage doesn't work. | ||
| Change the openat call to use the chase helper function to resolve the | ||
| symlink in the given root. | ||
| --- | ||
| src/shared/vpick.c | 4 ++-- | ||
| 1 file changed, 2 insertions(+), 2 deletions(-) | ||
|
|
||
| diff --git a/src/shared/vpick.c b/src/shared/vpick.c | ||
| index b1b2d93054..dfe58cafa5 100644 | ||
| --- a/src/shared/vpick.c | ||
| +++ b/src/shared/vpick.c | ||
| @@ -471,9 +471,9 @@ static int make_choice( | ||
| if (!p) | ||
| return log_oom_debug(); | ||
|
|
||
| - object_fd = openat(dir_fd, best_filename, O_CLOEXEC|O_PATH); | ||
| + object_fd = chase_and_openat(toplevel_fd, p, CHASE_AT_RESOLVE_IN_ROOT, O_PATH|O_CLOEXEC, NULL); | ||
| if (object_fd < 0) | ||
| - return log_debug_errno(errno, "Failed to open '%s/%s': %m", | ||
| + return log_debug_errno(object_fd, "Failed to open '%s/%s': %m", | ||
| empty_to_root(toplevel_path), skip_leading_slash(inode_path)); | ||
|
|
||
| return pin_choice( | ||
| -- | ||
| 2.52.0 | ||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,7 +1,7 @@ | ||
| From 83043596b6cc74b6f049999fa660afd983dc493a Mon Sep 17 00:00:00 2001 | ||
| From 61ae07bbf1d7032eef32137b1fe299647602e3de Mon Sep 17 00:00:00 2001 | ||
| From: David Michael <[email protected]> | ||
| Date: Tue, 16 Apr 2019 02:44:51 +0000 | ||
| Subject: [PATCH 1/8] wait-online: set --any by default | ||
| Subject: [PATCH] wait-online: set --any by default | ||
|
|
||
| The systemd-networkd-wait-online command would normally continue | ||
| waiting after a network interface is usable if other interfaces are | ||
|
|
@@ -11,22 +11,22 @@ Preserve previous Container Linux behavior for compatibility by | |
| setting the --any flag by default. See patches from v241 (or | ||
| earlier) for the original implementation. | ||
| --- | ||
| src/network/wait-online/wait-online.c | 2 +- | ||
| 1 file changed, 1 insertion(+), 1 deletion(-) | ||
| src/network/wait-online/wait-online.c | 3 ++- | ||
| 1 file changed, 2 insertions(+), 1 deletion(-) | ||
|
|
||
| diff --git a/src/network/wait-online/wait-online.c b/src/network/wait-online/wait-online.c | ||
| index 6f5aef903a..0acb3e76b9 100644 | ||
| index b1d0b9cde2..e07c11d807 100644 | ||
| --- a/src/network/wait-online/wait-online.c | ||
| +++ b/src/network/wait-online/wait-online.c | ||
| @@ -21,7 +21,7 @@ static Hashmap *arg_interfaces = NULL; | ||
| @@ -24,7 +24,7 @@ static Hashmap *arg_interfaces = NULL; | ||
| static char **arg_ignore = NULL; | ||
| static LinkOperationalStateRange arg_required_operstate = LINK_OPERSTATE_RANGE_INVALID; | ||
| static AddressFamily arg_required_family = ADDRESS_FAMILY_NO; | ||
| -static bool arg_any = false; | ||
| +static bool arg_any = true; | ||
| static bool arg_requires_dns = false; | ||
|
|
||
| STATIC_DESTRUCTOR_REGISTER(arg_interfaces, hashmap_free_free_freep); | ||
| STATIC_DESTRUCTOR_REGISTER(arg_ignore, strv_freep); | ||
| STATIC_DESTRUCTOR_REGISTER(arg_interfaces, hashmap_freep); | ||
| -- | ||
| 2.51.0 | ||
|
|
||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just to make sure I'm understanding this correctly, the reason we don't
mvhere is because the image only contains/usranyway, so/etcwill get thrown away in the end?That said, could you simplify this by just creating extension-release.00-flatcar-default under
${root_fs_dir}/etcand pointing systemd-repart at that?