In this tutorial, we will show you how to install Google Cloud SDK on Debian 10. For those of you who didn’t know, The Google Cloud SDK provides users with the ability to access Google Cloud via Terminal. It is a development toolkit that comes with multiple commands that help in managing the resources within the Google Cloud environment.
This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘
sudo‘ to the commands to get root privileges. I will show you through the step-by-step installation of the Google Cloud SDK on a Debian 10 (Buster).
Install Google Cloud SDK on Debian 10 Buster
Step 1. Before we install any software, it’s important to make sure your system is up to date by running the following
apt commands in the terminal:
sudo apt update sudo apt upgrade sudo apt install curl apt-transport-https ca-certificates gnupg
Step 2. Installing the Google Cloud SDK on Debian 10.
- Install Google Cloud SDK via Snap.
Run the following command to install Snap packages:
sudo apt install snapd sudo snap install core
To install Google Cloud SDK, simply use the following command:
sudo snap install google-cloud-sdk --classic
- Install the Google Cloud SDK via the official source.
Now we add the Cloud SDK distribution URI as a package source by running the commands below:
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
Next, import the Google Cloud public key by running the commands below:
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key --keyring /usr/share/keyrings/cloud.google.gpg add -
Now as the last step, we need to install the Google Cloud SDK:
sudo apt update sudo apt install google-cloud-sdk
Once done, next we run the following command to configure the SDK:
sudo gcloud init
Running the commands above will prompt you to authorize the Cloud SDK tools to use your Google account credentials to access Google Cloud and manage it.
Welcome! This command will take you through the configuration of gcloud. Your current configuration has been set to: [default] You can skip diagnostics next time by using the following flag: gcloud init --skip-diagnostics Network diagnostic detects and fixes local network connection issues. Checking network connection...done. Reachability Check passed. Network diagnostic passed (1/1 checks passed). You must log in to continue. Would you like to log in (Y/n)?
Congratulations! You have successfully installed Google Cloud. Thanks for using this tutorial for installing the Google Cloud SDK on Debian 10 Buster. For additional help or useful information, we recommend you check the official Google Cloud website.