From 2313eb1f3daba53d6443f7bc5f091133535cf521 Mon Sep 17 00:00:00 2001 From: Greg Hellings Date: Sun, 10 May 2026 01:31:11 -0500 Subject: [PATCH] Write explicit bashrc file --- img/builder.nix | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/img/builder.nix b/img/builder.nix index 6317844..f8c2e06 100644 --- a/img/builder.nix +++ b/img/builder.nix @@ -32,6 +32,13 @@ let ''; destination = "/etc/nix/nix.conf"; }; + bashrc = writeTextFile { + name = "bashrc"; + text = '' + export PATH=${lib.makeBinPath contents} + ''; + destination = "/etc/bashrc"; + }; contents = lib'.basePackages ++ [ buildah (fakeNss.override { @@ -52,9 +59,13 @@ let ]; in lib'.mkImage { - inherit contents; name = name "builder"; - config.Env = [ "TEMP=/tmp" "PATH=${lib.makeBinPath contents}" ]; + config.Env = [ + "TEMP=/tmp" + "PATH=${lib.makeBinPath contents}" + ]; + # Set this explicitly so that we avoid infinite recursion + contents = contents ++ [ bashrc ]; extraCommands = '' mkdir -p tmp mkdir -p var/tmp