Arch Linux BasedManjaro

How To Install Google Cloud SDK on Manjaro

Install Google Cloud SDK on Manjaro

In this tutorial, we will show you how to install Google Cloud SDK on Manjaro. Google Cloud SDK, also known as the gcloud command-line tool, is a powerful set of tools for interacting with Google Cloud Platform (GCP) services. It allows users to manage resources, deploy applications, and automate tasks directly from the command line. If you’re a Manjaro Linux user looking to work with GCP, installing Google Cloud SDK is a crucial step.

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 the step-by-step installation of the Google Cloud SDK on a Manjaro Linux.

Prerequisites

  • A server or desktop running one of the following operating systems: Manjaro, and other Arch-based distributions.
  • Basic familiarity with the command line interface (CLI).
  • SSH access to the server (or just open Terminal if you’re on a desktop).
  • A stable internet connection is crucial for downloading and installing packages. Verify your connection before proceeding.
  • Access to a Manjaro Linux system with a non-root sudo user or root user.

Install Google Cloud SDK on Manjaro

Step 1. Update Your System.

Before we begin the installation process, let’s ensure that your Manjaro system is ready. First and foremost, make sure your Manjaro distribution is up-to-date by running the following command in your terminal:

sudo pacman -Syu

This command will update your system’s packages and dependencies, ensuring compatibility with the Google Cloud SDK installation.

Step 2. Installing Dependencies.

Google Cloud SDK requires several dependencies to function correctly. Let’s install them using the pacman package manager:

sudo pacman -S python3 python3-pip curl unzip

Step 3. Installing Google Cloud SDK on Manjaro.

Visit the official Google Cloud SDK download page and locate the latest version for Linux. You can choose between a tarball file. For this guide, we’ll use the tarball option.

Copy the download link for the latest version and use curl to download it:

curl -O https://dl.google.com/dl/cloudsdk/channels/rapid/downloads/google-cloud-cli-472.0.0-linux-x86_64.tar.gz

Once the download is complete, extract the tarball using the tar command:

tar -xzf /google-cloud-cli-472.0.0-linux-x86_64.tar.gz

This command will extract the contents of the tarball to the current directory. It’s recommended to move the extracted directory to a more permanent location, such as /opt:

sudo mv google-cloud-sdk /opt/

The Google Cloud SDK comes with an install script that sets up the necessary environment variables and completes the installation process. Run the following command from the /opt/google-cloud-sdk directory:

./install.sh

The install script will guide you through the installation process. It will ask you whether you want to initialize the SDK after the installation is complete. Choose “Y” to initialize the SDK.

The script will also prompt you to choose which components to install. If you’re unsure, you can select the default components by pressing Enter.

After the installation is complete, you need to initialize the SDK. Run the following command:

gcloud init

This command will prompt you to log in to your Google account and select the project you want to use with the SDK. Follow the instructions provided in the terminal to complete the initialization process.

If you encounter any issues during the initialization process, such as authentication errors or project selection problems, refer to the official Google Cloud SDK documentation for troubleshooting steps.

Step 4. Authenticating with Google Cloud.

To interact with Google Cloud Platform services, you need to authenticate with your Google account. Run the following command to authenticate:

gcloud auth login

This command will open a web browser window and prompt you to log in to your Google account. Once you’ve logged in, the authentication process will be complete.

To verify that the Google Cloud SDK is installed correctly, run the following command:

gcloud version

This command will display the version of the Google Cloud SDK and its components. If the command runs without any errors and displays the version information, your installation was successful.

Google Cloud SDK is regularly updated with new features, bug fixes, and security improvements. To keep your installation up-to-date, run the following command:

gcloud components update

This command will check for available updates and install them if any are found. It’s recommended to update your SDK regularly to ensure you have access to the latest features and security patches.

Congratulations! You have successfully installed Google Cloud SDK. Thanks for using this tutorial to install the latest version of the Google Cloud SDK on the Manjaro system. For additional help or useful information, we recommend you check the official Google Cloud SDK website.

VPS Manage Service Offer
If you don’t have time to do all of this stuff, or if this is not your area of expertise, we offer a service to do “VPS Manage Service Offer”, starting from $10 (Paypal payment). Please contact us to get the best deal!

r00t

r00t is a seasoned Linux system administrator with a wealth of experience in the field. Known for his contributions to idroot.us, r00t has authored numerous tutorials and guides, helping users navigate the complexities of Linux systems. His expertise spans across various Linux distributions, including Ubuntu, CentOS, and Debian. r00t's work is characterized by his ability to simplify complex concepts, making Linux more accessible to users of all skill levels. His dedication to the Linux community and his commitment to sharing knowledge makes him a respected figure in the field.
Back to top button