depot/third_party/nixpkgs/pkgs/tools/admin/scaleway-cli/default.nix
Default email 4d5a95770c Project import generated by Copybara.
GitOrigin-RevId: 3c5319ad3aa51551182ac82ea17ab1c6b0f0df89
2023-03-04 15:14:45 +03:00

35 lines
905 B
Nix

{ lib, fetchFromGitHub, buildGoModule }:
buildGoModule rec {
pname = "scaleway-cli";
version = "2.11.1";
src = fetchFromGitHub {
owner = "scaleway";
repo = "scaleway-cli";
rev = "v${version}";
sha256 = "sha256-tE2r2d3dagMvfPq/2G61KMPZyz6YQG3jAD+MjQ3uYbg=";
};
vendorHash = "sha256-eqVAX6l7wsHqFjzwLiTSwryLHxl0aJqQOmjyGeM+1co=";
ldflags = [
"-w"
"-extldflags"
"-static"
"-X main.Version=${version}"
"-X main.GitCommit=ref/tags/${version}"
"-X main.GitBranch=HEAD"
"-X main.BuildDate=unknown"
];
# some tests require network access to scaleway's API, failing when sandboxed
doCheck = false;
meta = with lib; {
description = "Interact with Scaleway API from the command line";
homepage = "https://github.com/scaleway/scaleway-cli";
license = licenses.mit;
maintainers = with maintainers; [ nickhu techknowlogick ];
};
}