I am following instructions here to install Google Cloud SDK:
echo "deb [signed-by=/usr/share/keyrings/cloud.google.gpg] https://packages.cloud.google.com/apt cloud-sdk main" | sudo tee -a /etc/apt/sources.list.d/google-cloud-sdk.list
sudo apt-get install apt-transport-https ca-certificates gnupg
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key --keyring /usr/share/keyrings/cloud.google.gpg add -
sudo apt-get update && sudo apt-get install google-cloud-sdk
but in updating APT such that
$ sudo apt update
Hit:1 http://ftp.debian.org/debian unstable InRelease
Hit:2 http://deb.debian.org/debian experimental InRelease
Hit:3 https://updates.signal.org/desktop/apt xenial InRelease
Get:5 https://packages.cloud.google.com/apt cloud-sdk InRelease [6,337 B]
Err:5 https://packages.cloud.google.com/apt cloud-sdk InRelease
The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 6A030B21BA07F4FB
Hit:4 https://packages.cloud.google.com/apt kubernetes-xenial InRelease
Reading package lists... Done
W: GPG error: https://packages.cloud.google.com/apt cloud-sdk InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 6A030B21BA07F4FB
E: The repository 'https://packages.cloud.google.com/apt cloud-sdk InRelease' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
and in adding the key
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key add -
with Debian version
$ cat /etc/issue
Debian GNU/Linux 10 n l
How can I properly install Google Cloud SDK in Debian 10?
2
Answers
PO's Google support manual here is outdated. The new thread here fixed the issue:
The easiest way (from within debian VM or container):
apt-get update && apt-get install -y curl python
curl sdk.cloud.google.com -L | bash
Exit the VM (or container) and access it again.
gcloud init
And you are done.