change to writeShellApplication (#1)
use writeShellApplication to enable the automatic setting of PATH for dependencies. Reviewed-on: #1
This commit is contained in:
parent
2d0228de00
commit
1943c907c8
20
docker.nix
20
docker.nix
|
@ -1,6 +1,20 @@
|
|||
{ config, pkgs, ...}:
|
||||
|
||||
pkgs.dockerTools.streamLayeredImage {
|
||||
name = "node-red";
|
||||
config.Cmd = [ "${pkgs.nodePackages.node-red}/bin/node-red" ];
|
||||
let
|
||||
name = "node-red";
|
||||
entrypoint = pkgs.writeShellApplication {
|
||||
inherit name;
|
||||
|
||||
runtimeInputs = with pkgs; with nodePackages; [
|
||||
node-red
|
||||
ungoogled-chromium
|
||||
];
|
||||
|
||||
text = ''
|
||||
node-red
|
||||
'';
|
||||
};
|
||||
in pkgs.dockerTools.streamLayeredImage {
|
||||
inherit name;
|
||||
config.Cmd = [ "${entrypoint}/bin/entrypoint" ];
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user