Repository navigation
nix: fix NixOS tarball evaluation with pinned nixpkgs - #398
Open
DananjayaNadun wants to merge 1 commit into
Open
DananjayaNadun wants to merge 1 commit into
DananjayaNadun wants to merge 1 commit into
Conversation
The tarballs use nixpkgs revisions that predate services.journald.settings. Select the option interface exposed by the importing module so downstream users on newer nixpkgs keep their journal configuration too. Signed-off-by: Dananjaya Nadun <109723009+DananjayaNadun@users.noreply.github.com>
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Closes #387.
The NixOS rootfs module uses
services.journald.settings.Journalfor compatibility with newer Nixpkgs (#309). The project's three pinned Nixpkgs revisions still usestorage,audit, andextraConfig. The documented tarball build therefore fails during module evaluation.Select the journald interface declared by the importing NixOS module and share the five free-form settings between both paths. Both versions configure volatile storage and disable auditing.
Verification
With Nix 2.31.2 on x86_64 Linux, I reproduced the missing-option error on
cdadb9ebfor both the AArch64minimalandminimal-with-systemd-v259targets.With this change, I evaluated the generated
environment.etc."systemd/journald.conf".texton each of the three locked Nixpkgs revisions and on the upstream migration commit41dc9cb4d6990e28f3ef63c9d88ecb24ebeda8eb. All seven directives matched, including disabled audit (falseon the older revisions andnoon the newer one).The table summarizes the tarball checks on the patched commit.
minimalTo repeat an evaluation, substitute the target and variant in
nix eval --raw .#nixosDroidspacesTarballs.aarch64-linux.minimal.drvPath. To build the native image on x86_64 Linux, runnix build .#nixosDroidspacesTarballs.x86_64-linux.minimal. I extracted the journal configuration from the resulting 201 MiB archive and verified it matched the generated file byte for byte.