Skip to content

Commit

Permalink
nixos/podman: set preferLocalBuild on trivial runCommands
Browse files Browse the repository at this point in the history
  • Loading branch information
nbraud committed Sep 10, 2024
1 parent 81118d3 commit 61095e9
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion nixos/modules/virtualisation/podman/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ let
{
outputs = [ "out" "man" ];
inherit (podmanPackage) meta;
preferLocalBuild = true;
} ''
mkdir -p $out/bin
ln -s ${podmanPackage}/bin/podman $out/bin/docker
Expand Down Expand Up @@ -235,7 +236,10 @@ in
systemd.tmpfiles.packages = [
# The /run/podman rule interferes with our podman group, so we remove
# it and let the systemd socket logic take care of it.
(pkgs.runCommand "podman-tmpfiles-nixos" { package = cfg.package; } ''
(pkgs.runCommand "podman-tmpfiles-nixos" {
package = cfg.package;
preferLocalBuild = true;
} ''
mkdir -p $out/lib/tmpfiles.d/
grep -v 'D! /run/podman 0700 root root' \
<$package/lib/tmpfiles.d/podman.conf \
Expand Down

0 comments on commit 61095e9

Please sign in to comment.