feat: add basic docker image build
This commit is contained in:
parent
737ff501ab
commit
c697449b20
2 changed files with 11 additions and 0 deletions
9
docker.nix
Normal file
9
docker.nix
Normal file
|
|
@ -0,0 +1,9 @@
|
||||||
|
{ dockerTools, my-crate }:
|
||||||
|
dockerTools.buildLayeredImage {
|
||||||
|
name = my-crate.pname;
|
||||||
|
tag = "latest";
|
||||||
|
|
||||||
|
contents = [ my-crate ];
|
||||||
|
|
||||||
|
config.Cmd = [ ("/bin/" + my-crate.pname) ];
|
||||||
|
}
|
||||||
|
|
@ -123,6 +123,8 @@
|
||||||
my-crate-llvm-coverage = craneLibLLvmTools.cargoLlvmCov (commonArgs // {
|
my-crate-llvm-coverage = craneLibLLvmTools.cargoLlvmCov (commonArgs // {
|
||||||
inherit cargoArtifacts;
|
inherit cargoArtifacts;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
docker-image = pkgs.callPackage ./docker.nix { inherit my-crate; };
|
||||||
};
|
};
|
||||||
|
|
||||||
apps.default = flake-utils.lib.mkApp {
|
apps.default = flake-utils.lib.mkApp {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue