diff --git a/flake-modules/cuda.nix b/flake-modules/cuda.nix index 9618449..519f2e1 100644 --- a/flake-modules/cuda.nix +++ b/flake-modules/cuda.nix @@ -53,20 +53,9 @@ topLevel@{ flake-parts-lib, inputs, ... }: { # TODO: Figure out if we can use `pkgs.cudaPackages.cudnn.lib` instead of `pkgs.cudaPackages.cudnn`. The `.lib` one is smaller. pkgs.cudaPackages.cudnn ]; - config.devenvShellModule.containers.processes.layers = - ( - builtins.foldl' - (layers: cudaPackage: layers ++ [ - (inputs.nix2container.packages.${system}.nix2container.buildLayer { - deps = [ - cudaPackage - ]; - inherit layers; - }) - ]) - [ ] - common.config.cuda.packages - ); + config.devenvShellModule.containers.processes.layers = lib.mkBefore ( + builtins.map (cudaPackage: { deps = [ cudaPackage ]; }) common.config.cuda.packages + ); }; }; }); diff --git a/flake-modules/kubernetes.nix b/flake-modules/kubernetes.nix index 317a9a6..048365b 100644 --- a/flake-modules/kubernetes.nix +++ b/flake-modules/kubernetes.nix @@ -184,6 +184,11 @@ topLevel@{ flake-parts-lib, inputs, lib, ... }: { builtins.replaceStrings ["+"] ["_"] runtime.config.version }"; }; + options.devenvContainerName = lib.mkOption + { + type = lib.types.str; + default = "processes"; + }; options.pushImage = lib.mkOption { default = { }; @@ -223,7 +228,7 @@ topLevel@{ flake-parts-lib, inputs, lib, ... }: { } \ "''${skopeoCopyArgsArray[@]}" \ ${lib.escapeShellArgs [ - "nix:${perSystem.config.devenv.shells.${runtime.config.name}.containers.processes.derivation}" + "nix:${perSystem.config.devenv.shells.${runtime.config.name}.containers.${kubernetes.config.devenvContainerName}.derivation}" "docker://${kubernetes.config.remoteImage}" ]} ''; diff --git a/flake.lock b/flake.lock index d019ab9..6d630ce 100644 --- a/flake.lock +++ b/flake.lock @@ -26,11 +26,11 @@ "pre-commit-hooks": "pre-commit-hooks" }, "locked": { - "lastModified": 1711496471, - "narHash": "sha256-mGjEtPtWXJ/Pb80P/vcm65rL2Weq06fZemtBzFMgPjU=", + "lastModified": 1712101228, + "narHash": "sha256-4LQfsKTl4UA+mQ9O+4jJ9K7qvCBBhEIVH6lNshFq6Vo=", "owner": "Atry", "repo": "devenv", - "rev": "f99ec24a9ba904bb5790f8b2d6cb4b20fef2e468", + "rev": "42b5726802a32e7fd6c52d82b7f4fe88d6c1fd10", "type": "github" }, "original": {