Introduction
Laymen explanation
Technical explanation
gcloud is SDK for google cloud. It means that you can use this SDK in your client machine in order to interact with your google cloud account.
Useful link: https://cloud.google.com/sdk/gcloud/reference/compute/zones/list
Example to know about your current project and account info
google519822_student@k8s-workshop-module-1-lab:/kickstart$ gcloud info
Google Cloud SDK [204.0.0]
Platform: [Linux, x86_64] ('Linux', 'k8s-workshop-module-1-lab', '4.4.0-59-generic', '#80-Ubuntu SMP Fri Jan 6 17:47:47 UTC 2017', 'x86_64', 'x86_64')
Python Version: [2.7.12 (default, Nov 19 2016, 06:48:10) [GCC 5.4.0 20160609]]
Python Location: [/usr/bin/python2]
Site Packages: [Disabled]
Installation Root: [/usr/lib/google-cloud-sdk]
Installed Components:
core: [2018.06.04]
gsutil: [4.31]
gcloud: []
bq: [2.0.34]
System PATH: [/home/google519822_student/bin:/home/google519822_student/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin]
Python PATH: [/usr/lib/google-cloud-sdk/lib/third_party:/usr/lib/google-cloud-sdk/lib:/usr/lib/python2.7/:/usr/lib/python2.7/plat-x86_64-linux-gnu:/usr/lib/python2.7/lib-tk:/usr/lib/py
thon2.7/lib-old:/usr/lib/python2.7/lib-dynload]
Cloud SDK on PATH: [False]
Kubectl on PATH: [False]
WARNING: There are old versions of the Google Cloud Platform tools on your system PATH.
/usr/bin/git-credential-gcloud.sh
/usr/bin/bq
/usr/bin/gsutil
/usr/bin/gcloud
Installation Properties: [/usr/lib/google-cloud-sdk/properties]
User Config Directory: [/home/google519822_student/.config/gcloud]
Active Configuration Name: [default]
Active Configuration Path: [/home/google519822_student/.config/gcloud/configurations/config_default]
Account: [388506708402-compute@developer.gserviceaccount.com]
Project: [qwiklabs-gcp-bc143fd96f7558e5]
Current Properties:
[core]
project: [qwiklabs-gcp-bc143fd96f7558e5]
account: [388506708402-compute@developer.gserviceaccount.com]
Logs Directory: [/home/google519822_student/.config/gcloud/logs]
Last Log File: [/home/google519822_student/.config/gcloud/logs/2018.06.08/22.25.26.854585.log]
git: [git version 2.7.4]
ssh: [OpenSSH_7.2p2 Ubuntu-4ubuntu2.1, OpenSSL 1.0.2g 1 Mar 2016]
google519822_student@k8s-workshop-module-1-lab:/kickstart$ export GCP_PROJECT=`gcloud config list core/project --format='value(core.project)'`
google519822_student@k8s-workshop-module-1-lab:/kickstart$ echo $GCP_PROJECT
qwiklabs-gcp-bc143fd96f7558e5