Google Compute Engine lets you create and run virtual machines on Google infrastructure, running different operating systems, including Windows Server!
Follow along with this lab to learn about how to create a virtual machine with Windows Server and the ASP.NET framework installed. We will also create a Windows user and password and learn how to remote desktop into the Windows Server.
If you don't already have a Google Account (Gmail or Google Apps), you must create one. Sign-in to Google Cloud Platform console (console.cloud.google.com) and create a new project:
Remember the project ID, a unique name across all Google Cloud Platform projects. It will be referred to later in this codelab as
Next, you'll need to enable billing in Google Cloud Console in order to use Google Cloud Platform resources like Cloud Datastore and Cloud Storage.
New users of Google Cloud Platform are eligible for a $300 free trial. Running through this codelab shouldn't cost you more than a few dollars, but it could be more if you decide to use more resources or if you leave them running (see the "cleanup" section at the end of this document).
Google Cloud Marketplace lets you quickly deploy functional software packages that run on Google Cloud Platform. Even if you are unfamiliar with services like Compute Engine, you can easily spin up a familiar software package without having to manually configure the software, virtual machine instances, storage, or network settings.
Google Cloud Marketplace has the ASP.NET Framework solution that we will later use to install Windows Server, IIS, SQL Express, and ASP.NET with a single click.
In this section, we'll learn how to create a new Google Compute Engine virtual machine instance with Windows Server and ASP.NET Framework installed using Cloud Marketplace from Google Cloud Console.
Navigate to Google Cloud Console from another browser tab or window, to https://console.cloud.google.com. Use the login credentials you have set up when you signed up for Google Cloud Platform or those given to you by the lab proctor.
In Google Cloud Console, click the Menu icon for Products & services in the top left of the screen:
Then navigate to Cloud Marketplace
Type ASP.NET to search for ASP.NET Framework and then click on the result box below.
In the next screen, click on Launch on Compute Engine.
There are many parameters you can configure when creating a new instance. Let's use the following:
Learn more about zones in Regions & Zones documentation.
The n1-standard-1 is more than sufficient for our ASP.NET website, with 1 core and 3.75GiB of RAM. However, you can select smaller or larger machines, going all the way up to 32-core / 208GiB RAM. Learn more about this and custom machine types in the Machine Types documentation.
Note: A new project has a default resource quota, which may limit the number of CPU cores. You can request more for your projects.
Windows Server OS Version
Boot Disk Type
Note: You may optionally choose a more performant, solid state disk drive (SSD). See Storage Options.
Disk size in GB
We're using the default of 100GB, but you may adjust it to more or less depending on your needs.
Keep the defaults which will create firewall rules to allow HTTP, HTTPS traffic along with WebDeploy and RDF traffic.
Click on Deploy to create the new virtual machine instance with Windows Server and ASP.NET Framework! This will take you to a new page where you can see the progress.
Once finished, go to Compute Engine from the menu on the left and then select VM Instances. You should see the new virtual machine in the VM Instances list.
If you click on External IP, you should also see the default IIS website served from the instance.
Note that you can also Remote Desktop (RDP) into the machine but we need to create a Windows user and password first.
To create a Windows user and password, select Create or reset Windows password.
This will open a new window where you can create a user. Keep the default and select Set. After a few seconds, you should have a New Windows password dialog with the newly created password. Make a note of the password, as you will need it in the next section.
It's time to RDP into the Windows Server. You have two different ways, depending on whether you are on Windows or not. Let's go through them both.
If you are not on Windows but using Chrome, you can RDP directly from the browser using the Chrome RDP for Google Cloud Platform extension. Click on RDP.
This will prompt you to install Chrome RDP Extension. Once it is installed, it will open up a login page where you can use your Windows user and password to log in.
Alternatively, if you are on a Windows machine, you can download the RDP file by selecting it from the RDP menu.
On Windows, you can simply double click on the RDP file and login using the Windows user and password.
Once logged in, you should see the default Windows desktop with Google Cloud SDK Shell shortcut on the Desktop!
If you don't intend to use the VM instance in other codelabs, you can shutdown the VM instance to save on cost and to be an overall good cloud citizen. You can either decide to delete the instances or simply stop them, although keep in mind that stopped instances can still incur costs related to storage.
Google Compute Engine is the foundation to Google Cloud Platform's Infrastructure-as-a-Service. As you've seen, Cloud Marketplace makes it quite easy to get a Windows Server with ASP.NET Framework.