2022-06-16 17:23:12 +00:00
|
|
|
{ lib, buildGoModule, fetchFromGitHub }:
|
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "go-camo";
|
2023-02-22 10:55:15 +00:00
|
|
|
version = "2.4.3";
|
2022-06-16 17:23:12 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "cactus";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2023-02-22 10:55:15 +00:00
|
|
|
sha256 = "sha256-GRctsE+uAvyA0pcz+ym4sz3K80pUHoDipVsjFcdrT2A=";
|
2022-06-16 17:23:12 +00:00
|
|
|
};
|
|
|
|
|
2023-02-22 10:55:15 +00:00
|
|
|
vendorHash = "sha256-C66QxlMBupbHYktyzHapUrl0yk+pvWZN0BLhpjIGVzI=";
|
2022-06-16 17:23:12 +00:00
|
|
|
|
|
|
|
ldflags = [ "-s" "-w" "-X=main.ServerVersion=${version}" ];
|
|
|
|
|
|
|
|
preCheck = ''
|
|
|
|
# requires network access
|
|
|
|
rm pkg/camo/proxy_{,filter_}test.go
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "A camo server is a special type of image proxy that proxies non-secure images over SSL/TLS";
|
|
|
|
homepage = "https://github.com/cactus/go-camo";
|
|
|
|
changelog = "https://github.com/cactus/go-camo/releases/tag/v${version}";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ viraptor ];
|
|
|
|
};
|
|
|
|
}
|