FEATURES PRICING ABOUT DOCS LOGIN

Create a Google Compute Engine stack

Introduction

This guide will help you build Google Compute Engine stack. Google Cloud offers many services, one of which is Google Compute Engine which delivers virtual machines running in Google’s data centers and worldwide fiber network.

You can configure the number of VMs and applications installed on each VM instance. Along with configuring VM size and region. Your new team members will be able to use your stack to build their VMs environment and start working from day one.

You will need to have a Google Cloud account to be able to create VMs on Google Data Center. This will require you to provide your credit card information. You can sign up for a 60 day free trial and $300 in credit. Learn more about Google Compute Engine pricing.

Step by step guide

  1. Click ‘+’ sign to Create a New Stack

    Create new stack

  2. Choose Google Cloud Platform and click Create Stack

    Choose Google Cloud Platform

  3. Your default Google Cloud Platform stack is now created (If you wish you can give your stack a name by clicking on Edit Name below your stack name). In this modal you will find four tabs:

    1. Stack template: This is your stack template
    2. Custom variables: to define custom variables which you can use within your stack template, values there are hidden from the non-admin team members
    3. Readme: This will be the text displayed in a message box when your team builds the stack
    4. Credentials: add your Google Cloud Platform credentials here

    Stack template

  4. Edit your Readme file to greet your team and provide them with information regarding your project or stack

    Readme tab

  5. Setting up your Google Cloud Account. You need to add your Google Cloud Platform account credentials to the credentials tab. To do that, login to your Google Cloud Platform account, and follow the below steps:

    1. Create a new project:

      GCE New project

    2. Give your new Google Cloud project a name:

      GCE project name

    3. Once created, go to your project Dashboard, and click Enable and manage APIs.

      GCE project dashboard

      We need to enable Google Compute Engine API to allow Koding to create VMs on your Compute Engine account.

    4. Click Enable API

      GCE Enable APIs

    5. Click Compute Engine API

      GCE project APIs

    6. Click Enable to enable Compute Engine API

      GCE Enable Compute Engine API

    7. If your project doesn’t have Billing Enabled, you will be prompted to enable billing, click Enable Billing and follow the process to add your credit card information.

      You will not be billed if you signed up for a free trial. Your credit card information is used to confirm your identity. You should be notified when your Google Cloud trial period ends. Learn more about Google Compute Engine pricing.

      GCE Enable Billing

      Google Cloud applies resources quotas based on your usage, you may need to request quota increase, for both global and regional limit. See more information here

    8. Once you are done with adding your billing information, go to your project Credentials menu and click Create credentials

      GCE Credentials

    9. Choose Service Account Key

      GCE Service account

    10. Choose Compute Engine default service account from the drop down menu and choose JSON option. Click Create

      GCE JSON

    11. Your credential JSON file will be downloaded to your computer. You will use the contents of this file in your GCE Stack credentials tab. Make sure you know where it is located on your computer.

      GCE credentials downloaded

  6. Now that you have your Google Cloud credentials ready, let’s add them to Koding credentials tab. Open your Stack Credentials tab on Koding and add your credentials information:

    1. Title: Give your credentials a name
    2. Project ID: Every project on GCE has a unique ID. Add your project’s ID here. Here is a direct link to find your project ID
    3. Service account JSON key: copy & paste the contents of the credentials JSON file you downloaded earlier from your GCE account
    4. Region: choose the region you want to create your VM in

    GCE credentials tab

    Once you are done click Save this & continue to verify your credentials

  7. Once your credentials are saved & verified you will be directed back to your Stack template. Click Save on the top right

    GCE Save Stack

  8. Click Initialize to start your stack

    GCE Init Stack

  9. Now let’s start building our stack

    You will notice that the first page in the building stack window contains the message we wrote in our Read Me tab in our stack. This is the same message your team will see when they build their stack. It is a good practice to include information about your project or stack for your teammates.

    Click Next

    GCE Init Stack

  10. Make sure the correct credentials are selected (you can save multiple credentials) and click Build Stack

    GCE build stack

    Your stack will start building..

    GCE stack building

  11. Congratulations, your stack was built successfully, click Start Coding

    GCE stack built successfully

    You can now start working on your new VM

    VM ready

    You can also see your VM created on your GCE account

    VM on GCE

REQUEST A DEMO