Accessing the Google Cloud Console and Cloud Shell

Accessing the Google Cloud Console and Cloud Shell Qwiklab

  • Post comments:4 Comments
  • Reading time:7 mins read

Overview of Accessing the Google Cloud Console and Cloud Shell Qwiklab

In this lab, you become familiar with the Google Cloud web-based interface. Two integrated environments are available:

  • A GUI environment called the Google Cloud Console
  • A command-line interface called Cloud Shell, which has the commands from the Cloud SDK pre-installed

In this course, you use both environments.

You need to know a few things about the Google Cloud Console:

  • The Google Cloud Console is under continuous development, so the graphical layout occasionally changes. Often, these changes are made to accommodate new Google Cloud features or changes in the technology, resulting in a slightly different workflow.
  • You can perform most common Google Cloud actions in the Google Cloud Console. Sometimes new features are implemented in the Cloud SDK before they are made available in the Google Cloud Console.
  • The Google Cloud Console is extremely fast for some activities. The Google Cloud Console can perform multiple actions on your behalf that might require many command-line actions.
  • The commands in the Cloud SDK are valuable tools for automation.


In this lab, you learn how to perform the following tasks:

  • Learn how to access the Google Cloud Console and Cloud Shell
  • Become familiar with the Google Cloud Console
  • Become familiar with Cloud Shell features, including the Cloud Shell code editor
  • Use the Google Cloud Console and Cloud Shell to create buckets and VMs and service accounts
  • Perform other commands in Cloud Shell

Navigate to Google Cloud Storage and create a bucket

Cloud Storage allows worldwide storage and retrieval of any amount of data at any time. You can use Cloud Storage for a range of scenarios including serving website content, storing data for archival and disaster recovery, or distributing large data objects to users via direct download.

Cloud Storage buckets must have a globally unique name. In your organization, you should follow Google Cloud’s recommended best practices for naming buckets. For this lab, we can easily get a unique name for our bucket by using the ID of the Google Cloud project that Qwiklabs created for us because Google Cloud project IDs are also globally unique.

  1. In the Google Cloud Console, on the Navigation menu, click Home .
  2. In the Dashboard tab of the resulting screen, the Project info section shows your Google Cloud project ID. Select and copy the project ID. Because this project ID was created for you by Qwiklabs, it will resemble qwiklabs-gcp- followed by a long hexadecimal number.
  3. In the Google Cloud Console, on the Navigation menu, click Cloud Storage > Browser.
  4. Click Create bucket.
  5. For Name, paste in the Google Cloud project ID string you copied in an earlier step. These lab instructions will later refer to the name that you typed as [BUCKET_NAME].
  6. Click Continue.
  7. Click on Choose how to control access to objects and uncheck Enforce public access prevention on this bucket, now select Fine-grained.
  8. Click Continue.
  9. Leave all other values as their defaults.
  10. Click Create.

Create a virtual machine (VM) instance

Google Compute Engine offers virtual machines running in Google’s data centers and on its network as a service. Google Kubernetes Engine makes use of Compute Engine as a component of its architecture. For this reason, it’s helpful to learn a bit about Compute Engine before learning about Kubernetes Engine.

  1. On the Navigation menu, click Compute Engine > VM instances.
  2. Click Create Instance.
  3. For Name, type first-vm as the name for your instance.
  4. For Region, select us-central1.
  5. For Zone, select us-central1-c.
  6. For Machine type, examine the options.

The Machine type: menu lists the number of virtual CPUs, the amount of memory, and a symbolic name such as e1-standard-1. The symbolic name is the parameter you use to select the machine type when using the gcloud command to create a VM. To the right of the region, zone, and machine type is a per-month estimated cost.

  1. To see the breakdown of estimated costs, click Details to the right of the Machine type list underneath the estimated costs.
  2. For Machine type, click 2 vCPUs (e2-standard-2).

How did the cost change?

  1. For Machine type, click e2-micro (2 shared vCPU).

The micro type is a shared-core VM that is inexpensive.

  1. For Firewall, click Allow HTTP traffic.
  2. Leave the remaining settings as their defaults, and click Create.

Wait until the new VM is created.

Explore the VM details

  1. On the VM instances page, click the name of your VM, first-vm.
  2. Locate CPU platform, notice the value, and click Edit.

You can’t change the machine type, the CPU platform, or the zone of a running Google Cloud VM. You can add network tags and allow specific network traffic from the internet through firewalls.

Some properties of a VM are integral to the VM and are established when the VM is created. They cannot be changed. Other properties can be edited. For example, you can add disks, and you can determine whether the boot disk is deleted when the instance is deleted.

  1. Scroll down and examine Availability policies.

Compute Engine offers preemptible VM instances, which cost less per hour but can be terminated by Google Cloud at any time. These preemptible instances can save you a lot of money, but you must make sure that your workloads are suitable to be interrupted. You can’t convert a non-preemptible instance into a preemptible one. This choice must be made at VM creation.

If a VM is stopped for any reason (for example, an outage or a hardware failure), the automatic restart feature starts it back up. Is this the behavior you want? Are your applications idempotent (written to handle a second startup properly)?

During host maintenance, the VM is set for live migration. However, you can have the VM terminated instead of migrated.

If you make changes, they can sometimes take several minutes to be implemented, especially if they involve networking changes, like adding firewalls or changing the external IP.

  1. Click Cancel.

Create an IAM service account

An IAM service account is a special type of Google account that belongs to an application or a virtual machine, instead of to an individual end-user.

  1. On the Navigation menu, click IAM & admin > Service accounts.
  2. Click + Create service account.
  3. On the Service account details page, specify the Service account name as test-service-account.
  4. Click Create and Continue.
  5. On the Grant this service account access to project page, specify the role as Project > Editor.
  6. Click Continue.
  7. Click Done.
  8. On the Service accounts page, move to the extreme right of the test-service-account and click on the three dots.
  9. Click Manage keys.
  10. Click ADD KEY
  11. Select Create new key
  12. Select JSON as the key type.
  13. Click Create.

A JSON key file is downloaded. In a later step, you find this key file and upload it to the VM.

  1. Click Close.

Congratulations! You’re done with Kubernetes Engine Qwik Start.

Complete More Qwiklabs:

Creating a Virtual Machine Qwiklab

Getting Started with Cloud Shell and gcloud Qwiklab

Get Google Cloud Stickers: Get it Now

This Post Has 4 Comments

Leave a Reply