Objectives
In this tutorial, you learn about the following:
- Creating a Compute Engine instance template and managed instance group (MIG).
- Getting a domain name and certificate.
- Creating an HTTPS load balancer with a certificate.
- Enabling IAP.
- Testing that IAP is working.
Costs
This tutorial uses billable components of Google Cloud, including the following:
- Compute Engine
- 4 Virtual Machines (VMs)
- Networking
- Global Load Balancer Forwarding Rule
- Ingress Traffic
For a cost estimate based on projected usage, see this Pricing Calculator.
Before you begin
Before you start this tutorial, you need the following:
Select or create a Google Cloud project.
GO TO THE PROJECTS PAGEEnable billing for your project. Read about how to Modify a project's billing settings
Step 1: Create a Compute Engine template
In the Google Cloud console, go to the Compute Engine > Create an instance template page and select the project where you want to create a template.
GO TO THE CREATE AN INSTANCE TEMPLATE PAGE
Use the default values except for the following:
- Machine type:
- micro (f1-micro)
- Access scopes:
- Set access for each API
- Compute Engine: Read Only
- Firewall:
- Allow HTTP traffic
- In the Management section, under Automation > Startup script, copy and paste the following script: