From 37fd55c5e45632a8160817650647926296cd1766 Mon Sep 17 00:00:00 2001 From: Matthias Thym Date: Sun, 15 Oct 2023 20:47:31 +0200 Subject: [PATCH 1/5] google-cloud-sql-proxy: init at 0.12.0 --- .../google-cloud-bigtable-tool/default.nix | 40 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 + 2 files changed, 42 insertions(+) create mode 100644 pkgs/tools/misc/google-cloud-bigtable-tool/default.nix diff --git a/pkgs/tools/misc/google-cloud-bigtable-tool/default.nix b/pkgs/tools/misc/google-cloud-bigtable-tool/default.nix new file mode 100644 index 000000000000..97daf623d51b --- /dev/null +++ b/pkgs/tools/misc/google-cloud-bigtable-tool/default.nix @@ -0,0 +1,40 @@ +{ lib +, buildGoModule +, fetchFromGitHub +}: + +buildGoModule rec { + pname = "google-cloud-bigtable-tool"; + version = "0.12.0"; + + src = fetchFromGitHub { + owner = "googleapis"; + repo = "cloud-bigtable-cbt-cli"; + rev = "v.${version}"; + hash = "sha256-N5nbWMj7kLIdRiwBUWFz4Rat88Wx01i3hceMxAvSjaA="; + }; + + subPackages = [ "." ]; + + vendorHash = "sha256-kwvEfvHs6XF84bB3Ss1307OjId0nh/0Imih1fRFdY0M="; + + preCheck = '' + buildFlagsArray+="-short" + ''; + + meta = with lib; { + description = "Google Cloud Bigtable Tool"; + longDescription = '' + `cbt` is the Google Cloud Bigtable Tool. A CLI utility to interact with Google Cloud Bigtable. + The cbt CLI is a command-line interface for performing several different operations on Cloud Bigtable. + It is written in Go using the Go client library for Cloud Bigtable. + An overview of it's usage can be found in the [Google Cloud docs](https://cloud.google.com/bigtable/docs/cbt-overview). + For information about Bigtable in general, see the [overview of Bigtable](https://cloud.google.com/bigtable/docs/overview). + ''; + homepage = "https://github.com/googleapis/cloud-bigtable-cbt-cli"; + license = licenses.asl20; + maintainers = with maintainers; [ totoroot ]; + platforms = platforms.all; + mainProgram = "cbt"; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index a0f111bcf7e3..1aadcce3d5d4 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -8752,6 +8752,8 @@ with pkgs; with-gce = true; }; + google-cloud-bigtable-tool = callPackage ../tools/misc/google-cloud-bigtable-tool { }; + google-fonts = callPackage ../data/fonts/google-fonts { }; google-clasp = callPackage ../development/tools/google-clasp { }; From 32d8adf411348d1d2a2c54db0e4119334383b932 Mon Sep 17 00:00:00 2001 From: Matthias Thym Date: Sun, 15 Oct 2023 20:47:50 +0200 Subject: [PATCH 2/5] google-cloud-sql-proxy: rename from cloud-sql-proxy --- nixos/doc/manual/release-notes/rl-2311.section.md | 2 ++ .../tools/misc/google-cloud-bigtable-tool/default.nix | 2 +- .../default.nix | 11 ++++++++++- pkgs/top-level/all-packages.nix | 4 ++-- 4 files changed, 15 insertions(+), 4 deletions(-) rename pkgs/tools/misc/{cloud-sql-proxy => google-cloud-sql-proxy}/default.nix (51%) diff --git a/nixos/doc/manual/release-notes/rl-2311.section.md b/nixos/doc/manual/release-notes/rl-2311.section.md index b990c20796ee..5444bd978ef3 100644 --- a/nixos/doc/manual/release-notes/rl-2311.section.md +++ b/nixos/doc/manual/release-notes/rl-2311.section.md @@ -264,6 +264,8 @@ - Package `noto-fonts-emoji` was renamed to `noto-fonts-color-emoji`; see [#221181](https://github.com/NixOS/nixpkgs/issues/221181). +- Package `cloud-sql-proxy` was renamed to `google-cloud-sql-proxy` as it cannot be used with other cloud providers.; + - Package `pash` was removed due to being archived upstream. Use `powershell` as an alternative. - `security.sudo.extraRules` now includes `root`'s default rule, with ordering diff --git a/pkgs/tools/misc/google-cloud-bigtable-tool/default.nix b/pkgs/tools/misc/google-cloud-bigtable-tool/default.nix index 97daf623d51b..6bcc11a43f5f 100644 --- a/pkgs/tools/misc/google-cloud-bigtable-tool/default.nix +++ b/pkgs/tools/misc/google-cloud-bigtable-tool/default.nix @@ -28,7 +28,7 @@ buildGoModule rec { `cbt` is the Google Cloud Bigtable Tool. A CLI utility to interact with Google Cloud Bigtable. The cbt CLI is a command-line interface for performing several different operations on Cloud Bigtable. It is written in Go using the Go client library for Cloud Bigtable. - An overview of it's usage can be found in the [Google Cloud docs](https://cloud.google.com/bigtable/docs/cbt-overview). + An overview of its usage can be found in the [Google Cloud docs](https://cloud.google.com/bigtable/docs/cbt-overview). For information about Bigtable in general, see the [overview of Bigtable](https://cloud.google.com/bigtable/docs/overview). ''; homepage = "https://github.com/googleapis/cloud-bigtable-cbt-cli"; diff --git a/pkgs/tools/misc/cloud-sql-proxy/default.nix b/pkgs/tools/misc/google-cloud-sql-proxy/default.nix similarity index 51% rename from pkgs/tools/misc/cloud-sql-proxy/default.nix rename to pkgs/tools/misc/google-cloud-sql-proxy/default.nix index 48783fddd654..aa93c5be935f 100644 --- a/pkgs/tools/misc/cloud-sql-proxy/default.nix +++ b/pkgs/tools/misc/google-cloud-sql-proxy/default.nix @@ -4,7 +4,7 @@ }: buildGoModule rec { - pname = "cloud-sql-proxy"; + pname = "google-cloud-sql-proxy"; version = "2.7.0"; src = fetchFromGitHub { @@ -24,9 +24,18 @@ buildGoModule rec { meta = with lib; { description = "Utility for ensuring secure connections to Google Cloud SQL instances"; + longDescription = '' + The Cloud SQL Auth Proxy is a utility for ensuring secure connections to your Cloud SQL instances. + It provides IAM authorization, allowing you to control who can connect to your instance through IAM permissions, + and TLS 1.3 encryption, without having to manage certificates. + See the [Connecting Overview](https://cloud.google.com/sql/docs/mysql/connect-overview) page for more information + on connecting to a Cloud SQL instance, or the [About the Proxy](https://cloud.google.com/sql/docs/mysql/sql-proxy) + page for details on how the Cloud SQL Proxy works. + ''; homepage = "https://github.com/GoogleCloudPlatform/cloud-sql-proxy"; license = licenses.asl20; maintainers = with maintainers; [ nicknovitski totoroot ]; + platforms = platforms.all; mainProgram = "cloud-sql-proxy"; }; } diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 1aadcce3d5d4..3bd51a704cb7 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -3615,8 +3615,6 @@ with pkgs; clairvoyance = callPackage ../tools/security/clairvoyance { }; - cloud-sql-proxy = callPackage ../tools/misc/cloud-sql-proxy { }; - cloudfox = callPackage ../tools/security/cloudfox { }; cloudhunter = callPackage ../tools/security/cloudhunter { }; @@ -8754,6 +8752,8 @@ with pkgs; google-cloud-bigtable-tool = callPackage ../tools/misc/google-cloud-bigtable-tool { }; + google-cloud-sql-proxy = callPackage ../tools/misc/google-cloud-sql-proxy { }; + google-fonts = callPackage ../data/fonts/google-fonts { }; google-clasp = callPackage ../development/tools/google-clasp { }; From 726b85ff99fc37b6d06a533f2d679ab974c6415e Mon Sep 17 00:00:00 2001 From: Matthias Thym Date: Mon, 16 Oct 2023 07:14:16 +0200 Subject: [PATCH 3/5] Update pkgs/tools/misc/google-cloud-bigtable-tool/default.nix Remove unnecessary statement. Co-authored-by: Janik <80165193+Janik-Haag@users.noreply.github.com> --- pkgs/tools/misc/google-cloud-bigtable-tool/default.nix | 2 -- 1 file changed, 2 deletions(-) diff --git a/pkgs/tools/misc/google-cloud-bigtable-tool/default.nix b/pkgs/tools/misc/google-cloud-bigtable-tool/default.nix index 6bcc11a43f5f..80701dfae431 100644 --- a/pkgs/tools/misc/google-cloud-bigtable-tool/default.nix +++ b/pkgs/tools/misc/google-cloud-bigtable-tool/default.nix @@ -14,8 +14,6 @@ buildGoModule rec { hash = "sha256-N5nbWMj7kLIdRiwBUWFz4Rat88Wx01i3hceMxAvSjaA="; }; - subPackages = [ "." ]; - vendorHash = "sha256-kwvEfvHs6XF84bB3Ss1307OjId0nh/0Imih1fRFdY0M="; preCheck = '' From 3b2f4e99db6a0b3e25cca03d467279de8c842e41 Mon Sep 17 00:00:00 2001 From: Matthias Thym Date: Mon, 16 Oct 2023 07:57:28 +0200 Subject: [PATCH 4/5] Update pkgs/tools/misc/google-cloud-bigtable-tool/default.nix Remove platforms meta attribute. --- pkgs/tools/misc/google-cloud-bigtable-tool/default.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/pkgs/tools/misc/google-cloud-bigtable-tool/default.nix b/pkgs/tools/misc/google-cloud-bigtable-tool/default.nix index 80701dfae431..3c61159bf972 100644 --- a/pkgs/tools/misc/google-cloud-bigtable-tool/default.nix +++ b/pkgs/tools/misc/google-cloud-bigtable-tool/default.nix @@ -32,7 +32,6 @@ buildGoModule rec { homepage = "https://github.com/googleapis/cloud-bigtable-cbt-cli"; license = licenses.asl20; maintainers = with maintainers; [ totoroot ]; - platforms = platforms.all; mainProgram = "cbt"; }; } From 0365ed6aab6231410f731778d87a7acdec015f50 Mon Sep 17 00:00:00 2001 From: Matthias Thym Date: Mon, 16 Oct 2023 07:58:01 +0200 Subject: [PATCH 5/5] Update pkgs/tools/misc/google-cloud-bigtable-tool/default.nix Remove platforms meta attribute. --- pkgs/tools/misc/google-cloud-sql-proxy/default.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/pkgs/tools/misc/google-cloud-sql-proxy/default.nix b/pkgs/tools/misc/google-cloud-sql-proxy/default.nix index aa93c5be935f..7257f411d521 100644 --- a/pkgs/tools/misc/google-cloud-sql-proxy/default.nix +++ b/pkgs/tools/misc/google-cloud-sql-proxy/default.nix @@ -35,7 +35,6 @@ buildGoModule rec { homepage = "https://github.com/GoogleCloudPlatform/cloud-sql-proxy"; license = licenses.asl20; maintainers = with maintainers; [ nicknovitski totoroot ]; - platforms = platforms.all; mainProgram = "cloud-sql-proxy"; }; }