This is a step by step tutorial for setting up Google Cloud CLI on your laptop. I’m using a Mac machine, so this tutorial is focused on going through the setup for Mac.
Install the latest gcloud CLI version
- Make sure you have supported version of Python, which is 3.5 to 3.9 (10/27/2022).
- Go to this website to install gcloud CLI on your machine. Choose the OS of your laptop.
- Extract the file on your home directory.
- Initialize the gcloud CLI, open your terminal and type the following:
gcloud init
- You’ll be asked to configure things like project ID and emails associated with your GCP account/project.
- Now that you’ve installed gcloud CLI, you will make sure by typing the following:
gcloud --help
And that’s it! You configured google cloud CLI on your local machine.
If you want to double check that you can actually do stuff from my local machine for GCP, check out this blog post that talks about deploying a simple cloud function from a local machine to GCP.
References: