3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/applications/networking/cloudflared/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

39 lines
1.1 KiB
Nix
Raw Normal View History

{ lib, buildGoModule, fetchFromGitHub, stdenv }:
buildGoModule rec {
pname = "cloudflared";
2022-05-30 15:21:05 +01:00
version = "2022.5.2";
src = fetchFromGitHub {
owner = "cloudflare";
repo = "cloudflared";
rev = version;
2022-05-30 15:21:05 +01:00
hash = "sha256-xE/Bc+6Ob2u4tQQoykoaa8MhFH2czwz5rMABUqfXNMM=";
};
2020-06-09 11:19:16 +01:00
vendorSha256 = null;
2021-08-26 07:45:51 +01:00
ldflags = [ "-X main.Version=${version}" ];
preCheck = ''
# Workaround for: sshgen_test.go:74: mkdir /homeless-shelter/.cloudflared: no such file or directory
export HOME="$(mktemp -d)";
# Workaround for: protocol_test.go:11:
# lookup protocol-v2.argotunnel.com on [::1]:53: read udp [::1]:51876->[::1]:53: read: connection refused
substituteInPlace "edgediscovery/protocol_test.go" \
--replace "TestProtocolPercentage" "SkipProtocolPercentage"
'';
doCheck = !stdenv.isDarwin;
meta = with lib; {
2022-02-12 17:15:12 +00:00
description = "CloudFlare Tunnel daemon (and DNS-over-HTTPS client)";
homepage = "https://www.cloudflare.com/products/tunnel";
license = licenses.asl20;
platforms = platforms.unix;
2022-04-07 19:28:57 +01:00
maintainers = with maintainers; [ bbigras enorris thoughtpolice techknowlogick ];
};
}