mirror of
https://github.com/apricote/hcloud-upload-image.git
synced 2026-01-13 21:31:03 +00:00
30 lines
685 B
Nix
30 lines
685 B
Nix
|
|
{
|
||
|
|
lib,
|
||
|
|
buildGoModule,
|
||
|
|
}:
|
||
|
|
buildGoModule rec {
|
||
|
|
pname = "hcloud-upload-image";
|
||
|
|
version =
|
||
|
|
builtins.head (builtins.match ".*version = \"([0-9.]+)\".*"
|
||
|
|
(builtins.readFile ./internal/version/version.go));
|
||
|
|
|
||
|
|
src = ./.;
|
||
|
|
vendorHash = "sha256-HPskDotHX5GnbuL2KkoqRiY4G1MxOvwJBMBPDCIzHvE=";
|
||
|
|
env.GOWORK = "off";
|
||
|
|
subPackages = ["."];
|
||
|
|
|
||
|
|
ldflags = [
|
||
|
|
"-s"
|
||
|
|
"-w"
|
||
|
|
"-X main.version=${version}"
|
||
|
|
];
|
||
|
|
|
||
|
|
meta = {
|
||
|
|
description = "Quickly upload any raw disk images into your Hetzner Cloud projects";
|
||
|
|
homepage = "https://github.com/apricote/hcloud-upload-image";
|
||
|
|
license = lib.licenses.mit;
|
||
|
|
maintainers = [];
|
||
|
|
mainProgram = "hcloud-upload-image";
|
||
|
|
};
|
||
|
|
}
|