Skip to content

Usage of git conflicts with the Perl-less profile #423

@StarryReverie

Description

@StarryReverie

Hi there! Thank you developers for making such an awesome project.

Recently I'd like to enable the usage of Perl-less activation for my homelab running MicroVM clusters. By inspecting Nixpkgs, I learnt that this can be done by adding:

{
  imports = [
    (modulesPath + "profiles/perlless.nix")
  ]
}

As I run sudo nixos-rebuild switch, the build process, however, failed with the following error message:

nixos-system-starrynix-homelab> System closure /nix/store/2zm8aiip3i5lalan63hqg333wv7qfbsl-nixos-system-starrynix-homelab-25.11.20251025.6a08e6b contains the following disallowed paths:
nixos-system-starrynix-homelab> /nix/store/0n4pjifqyzsscnm28vsx99nvzi7rvjkp-perl5.40.0-HTTP-Cookies-6.10
nixos-system-starrynix-homelab> /nix/store/1gsknjqa93qli2nw68cc7gmgxsfhhnim-perl5.40.0-HTML-Tagset-3.20
nixos-system-starrynix-homelab> /nix/store/1id789x3gwg5aan8diyqnbrqjdifmwif-perl5.40.0-Digest-HMAC-1.05
nixos-system-starrynix-homelab> /nix/store/2j1zjih276h725w84hcscn6ahkm6a0px-perl5.40.0-libwww-perl-6.72
nixos-system-starrynix-homelab> /nix/store/4smyg8r1inrfyqs4knyds2371nhhaxxi-perl5.40.0-FCGI-0.82
nixos-system-starrynix-homelab> /nix/store/4vrla4iysq1s3a4x36vrrl19ch5jzqnz-perl5.40.0-HTTP-Negotiate-6.01
nixos-system-starrynix-homelab> /nix/store/53s04486vl8mp5p8y14zk90wdh8z9ygi-perl5.40.0-HTTP-CookieJar-0.014
nixos-system-starrynix-homelab> /nix/store/5acqp6qajgihjkah3wdjwvyfz6q0namh-perl5.40.0-Mozilla-CA-20230821
nixos-system-starrynix-homelab> /nix/store/5bsnkm7mi10gszpdxxhmr7h7bx1bhdin-perl5.40.0-Test-RequiresInternet-0.05
nixos-system-starrynix-homelab> /nix/store/5mmprpajlg6gpbwrmsimn97833gjm8ki-perl5.40.0-Net-SMTP-SSL-1.04
nixos-system-starrynix-homelab> /nix/store/7cdwccydj3hfvvgbhfp712a81hsi19c4-perl5.40.0-Net-SSLeay-1.92
nixos-system-starrynix-homelab> /nix/store/7g8p6p3r211kl932j9j451qzgrw0khrg-perl5.40.0-LWP-MediaTypes-6.04
nixos-system-starrynix-homelab> /nix/store/8s0dasm0k9273dcvg1mdg48zk5vbk3dp-perl5.40.0-Clone-0.46
nixos-system-starrynix-homelab> /nix/store/bqnrzkrn19dkdlzvw7dcanryzj8wk21d-perl5.40.0-Test-Fatal-0.017
nixos-system-starrynix-homelab> /nix/store/c7xw73aks4z7p23y1hhixhhf25cn43i0-perl5.40.0-HTML-TagCloud-0.38
nixos-system-starrynix-homelab> /nix/store/f91yxyy6s6kvw7dfhp0jyg1jfs4shxmi-perl5.40.0-URI-5.21
nixos-system-starrynix-homelab> /nix/store/fcdpmsg6wbfvc8g1qvixgha6f6iys314-perl5.40.0-HTTP-Date-6.06
nixos-system-starrynix-homelab> /nix/store/ffiflghs8d650s3jiihks23p3h1z5y4g-perl5.40.0-Net-HTTP-6.23
nixos-system-starrynix-homelab> /nix/store/frsgwsg9sdhm9zx9ngw9b8xndawb32fj-perl5.40.0-IO-Socket-SSL-2.083
nixos-system-starrynix-homelab> /nix/store/g7k6fv5hdrklcz8zs4y84w55f2jbbfxf-perl5.40.0-Test-Needs-0.002010
nixos-system-starrynix-homelab> /nix/store/gpr6l2dy4pfprnhq87v9di0izjqyh9fn-perl5.40.0-HTTP-Daemon-6.16
nixos-system-starrynix-homelab> /nix/store/gqigfxm9b626q8z3rn592c9qjk9p9ypf-perl5.40.0-TimeDate-2.33
nixos-system-starrynix-homelab> /nix/store/i4h5jgmrbzdka66hxycfsk095f1y9jbd-perl5.40.0-IO-HTML-1.004
nixos-system-starrynix-homelab> /nix/store/kifsc9q6vlw01ic5nyk1gipnvmy1iij2-perl-5.40.0
nixos-system-starrynix-homelab> /nix/store/lqma0j2l853wm19r3rh700fkygvgp7yc-perl5.40.0-TermReadKey-2.38
nixos-system-starrynix-homelab> /nix/store/pbxldghfdd47m6mz1j7jail113wnwb44-perl5.40.0-WWW-RobotRules-6.02
nixos-system-starrynix-homelab> /nix/store/pjmrs6vng4fi0vdr7dzdwhhg4ri8lw9v-perl5.40.0-File-Listing-6.16
nixos-system-starrynix-homelab> /nix/store/q0bi4qxmaya464l3qswly473nyhip4j5-perl5.40.0-CGI-Fast-2.16
nixos-system-starrynix-homelab> /nix/store/qh64w3f3hy3dpq90w8iml899a1iw1dz6-perl5.40.0-Encode-Locale-1.05
nixos-system-starrynix-homelab> /nix/store/qmhailwnhm07cac86v385kxzj49aks3m-perl5.40.0-Authen-SASL-2.1900
nixos-system-starrynix-homelab> /nix/store/qsgq00zmphdyjplwrvjiidsckgb5k4fa-perl5.40.0-FCGI-ProcManager-0.28
nixos-system-starrynix-homelab> /nix/store/x64fqg9f0is2mhdxai2mjsy6a1vs3jgq-perl5.40.0-libnet-3.15
nixos-system-starrynix-homelab> /nix/store/x9613s5v2y6x9qlxjfjb27693mbdknxs-perl5.40.0-Crypt-URandom-0.54
nixos-system-starrynix-homelab> /nix/store/xpg5nkdxnpccdr4fylwd0iwv28kv89sd-perl5.40.0-HTML-Parser-3.81
nixos-system-starrynix-homelab> /nix/store/y81syny5q4647y0pfgpfjxkq7xyhzpmg-perl5.40.0-Try-Tiny-0.31
nixos-system-starrynix-homelab> /nix/store/ysqbaxvvzvn0llccf1wjxyy2dqzns85h-perl5.40.0-CGI-4.59
nixos-system-starrynix-homelab> /nix/store/zincfiichkh6y7dk8mwsgljjhljbwfy6-perl5.40.0-HTTP-Message-6.45
error: Cannot build '/nix/store/18jimdkdskajxi4bx28br1fn0nijcxns-nixos-system-starrynix-homelab-25.11.20251025.6a08e6b.drv'.
       Reason: builder failed with exit code 1.
       Output paths:
         /nix/store/2zm8aiip3i5lalan63hqg333wv7qfbsl-nixos-system-starrynix-homelab-25.11.20251025.6a08e6b
Command 'nix --extra-experimental-features 'nix-command flakes' build --print-out-paths '.#nixosConfigurations."homelab".config.system.build.toplevel' --print-build-logs --no-link' returned non-zero exit status 1.

I ran nix why-depends <my-nixos-generation> <perl-package> and got the following output:

nix why-depends /nix/store/0738dllmzk82x2bdfhf55xhs5xry5ccp-nixos-system-starrynix-homelab-25.11.20251025.6a08e6b /nix/store/zincfiichkh6y7dk8mwsgljjhljbwfy6-perl5.40.0-HTTP-Message-6.45
/nix/store/0738dllmzk82x2bdfhf55xhs5xry5ccp-nixos-system-starrynix-homelab-25.11.20251025.6a08e6b
└───/nix/store/j9jbn5czw771ck748cp6b9c93fzj61a4-system-path
    └───/nix/store/lqyydad9sisqd9rpyrh6b4rbjcjw670b-microvm
        └───/nix/store/60440kg5c51rrlpinkk2rkg020q5q6kv-git-2.51.0
            └───/nix/store/2j1zjih276h725w84hcscn6ahkm6a0px-perl5.40.0-libwww-perl-6.72
                └───/nix/store/zincfiichkh6y7dk8mwsgljjhljbwfy6-perl5.40.0-HTTP-Message-6.45

which indicates that microvm.nix indirectly depends on Perl through Git.

Two references to git are found at

PATH=${lib.makeBinPath [ coreutils git nix ]}
and .

Can this be avoided by replace git with gitMinimal? It seems that none of the Perl functionalities is required by git in those two scripts. I can currently work around this problem by applying overlays, but from my perspective, this is not a clean solution compared to only relying on the core subset of Git.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions