diff --git a/default.nix b/default.nix index da12163..fcbcc26 100644 --- a/default.nix +++ b/default.nix @@ -9,6 +9,9 @@ let self = { MoonPlus = callPackage ./pkgs/moonplus { }; + minica = callPackage ./pkgs/minica { }; + + # x appsluggr = x.appsluggr; johaus = x.johaus; license = x.license; diff --git a/docker/moonplus.nix b/docker/moonplus.nix new file mode 100644 index 0000000..3533db4 --- /dev/null +++ b/docker/moonplus.nix @@ -0,0 +1,22 @@ +{ system ? builtins.currentSystem }: + +let + pkgs = import { inherit system; }; + + callPackage = pkgs.lib.callPackageWith pkgs; + + moonplus = callPackage ../pkgs/moonplus { }; + + dockerImage = pkg: + pkgs.dockerTools.buildImage { + name = pkg.name; + tag = "latest"; + + contents = [ pkg ]; + + config = { + Cmd = [ "/bin/${pkg.name}" ]; + }; + }; + +in dockerImage moonplus diff --git a/pkgs/minica/default.nix b/pkgs/minica/default.nix new file mode 100644 index 0000000..f5ffb4f --- /dev/null +++ b/pkgs/minica/default.nix @@ -0,0 +1,21 @@ +{ pkgs ? import { } }: +let + version = "1.0.2"; + + repo = pkgs.fetchFromGitHub { + owner = "jsha"; + repo = "minica"; + rev = "v${version}"; + hash = "sha256:18518wp3dcjhf3mdkg5iwxqr3326n6jwcnqhyibphnb2a58ap7ny"; + }; + + out = pkgs.buildGoModule { + pname = "minica"; + version = version; + src = repo; + modSha256 = "sha256:0sjjj9z1dhilhpc8pq4154czrb79z9cm044jvn75kxcjv6v5l2m5"; + + subPackages = [ "." ]; + }; + +in out