1{ lib, buildGoModule, fetchFromGitHub }:
2
3buildGoModule rec {
4 pname = "cloud-sql-proxy";
5 version = "1.31.2";
6
7 src = fetchFromGitHub {
8 owner = "GoogleCloudPlatform";
9 repo = "cloudsql-proxy";
10 rev = "v${version}";
11 sha256 = "sha256-wlMwl1S9WKtCoruKhMVK1197/3/OWhvvXTT1tH/yPlI=";
12 };
13
14 subPackages = [ "cmd/cloud_sql_proxy" ];
15
16 vendorSha256 = "sha256-OMvu0LCYv0Z03ZM2o8UZx/Su2rdvTJp5DUZa8/MtQSc=";
17
18 preCheck = ''
19 buildFlagsArray+="-short"
20 '';
21
22 meta = with lib; {
23 description = "An authenticating proxy for Second Generation Google Cloud SQL databases";
24 homepage = "https://github.com/GoogleCloudPlatform/cloudsql-proxy";
25 license = licenses.asl20;
26 maintainers = with maintainers; [ nicknovitski ];
27 mainProgram = "cloud_sql_proxy";
28 };
29}