Creating a Virtual Machine



Compute Engine lets you create virtual machines that run different operating systems, including multiple flavors of Linux (Debian, Ubuntu, Suse, Red Hat, CoreOS) and Windows Server, on Google infrastructure. You can run thousands of virtual CPUs on a system that is designed to be fast and to offer strong consistency of performance.

In this hands-on lab, you'll create virtual machine instances of various machine types using the Google Cloud Console and the gcloud command line. You'll also learn how to connect an NGINX web server to your virtual machine.

Create new Instance via Cloud Console

Head over to the VM Instances page as shown below.

Create a VM Instance with the specs below.

Once the VM spawns, it will look like the following. Hit the SSH button to continue configuring it if needed.

Installing NGINX web server

This is pretty straight forward

sudo su -
apt-get update
apt-get install nginx -y

Confirm that its successfully installed, up and running.

ps auwx | grep nginx

We are able to see that root is running the NGINX service. We can also confirm this by heading over to the VMs public IP via a web browser as shown below.

Last updated