diff options
author | Emile <git@emile.space> | 2025-02-12 22:05:22 +0100 |
---|---|---|
committer | Emile <git@emile.space> | 2025-02-12 22:05:22 +0100 |
commit | 7152205c80f059d3649e1830fb4dfc46d1fc158f (patch) | |
tree | b0d9a9aea760fabd61ee5cb06814d45cac5bb629 /nix/templates/goapp/frontend/default.nix | |
parent | 4d08790c43b2d0720ef43b657a651a7c541d30d2 (diff) |
template: the goapp docker package should now (in theory) build
It's quite a weird way to pull out the packge name from the attribute set of defined packages, yet it kind of works. I can't test it, as docker doesn't want to run Mach-O binaries, but kicking this into hydra should result in some nice builds.
Diffstat (limited to 'nix/templates/goapp/frontend/default.nix')
-rw-r--r-- | nix/templates/goapp/frontend/default.nix | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/nix/templates/goapp/frontend/default.nix b/nix/templates/goapp/frontend/default.nix index 1a3aeeb..f4ed3a4 100644 --- a/nix/templates/goapp/frontend/default.nix +++ b/nix/templates/goapp/frontend/default.nix @@ -1,21 +1,16 @@ -{ pkgs, packagename, ... }: +{ pkgs, name, ... }: let version = "0.0.1"; in pkgs.buildGoModule { - name = "${packagename}-${version}"; - pname = "${packagename}"; + name = "${name}-${version}"; + pname = "${name}"; version = "${version}"; src = ./.; - subPackages = [ "src" ]; - vendorHash = "sha256-8wYERVt3PIsKkarkwPu8Zy/Sdx43P6g2lz2xRfvTZ2E="; - - postInstall = '' - mkdir -p $out - mv $out/bin/src $out/bin/${packagename} - ''; + subPackages = [ "" ]; + vendorHash = "sha256-tIk8lmyuVETrOW7fA7K7uNNXAAtJAYSM4uH+xZaMWqc="; doCheck = true; } |