Skip to content
This repository has been archived by the owner on Oct 12, 2021. It is now read-only.

Latest commit

 

History

History
118 lines (85 loc) · 4.5 KB

gce-setup.md

File metadata and controls

118 lines (85 loc) · 4.5 KB

Setting up Shipshape on Google Compute Engine

We offer a prefabricated Shipshape image on Google Compute Engine. In order to use it, all you need is a GCE project. You can create a project by following these instructions. Note that only the instructions in the section labeled Set up a Google Cloud Platform project are necessary; don't follow the instructions in the subsequent sections.

Creating an Instance with the GCE Console

The quickest way to get a running Shipshape instance on GCE is to use the Developers Console to import our prefabricated image.

Getting the Shipshape Image

To begin, navigate to the Google Developers Console and select your project. Then, in the sidebar on the left, navigate to

Compute → Compute Engine → Images

After this, click on the New Image button at the top of the page. This should open the Create a new image form. Most of the fields presented to you here are pretty self explanatory; however, for the final two you should use the following values

|--------------------------|------------------------| | Source | Cloud Storage file | | Cloud Storage file | $image_bucket_path |

Make sure to take note of the value you provided in the Name field, and then click Create at the bottom of the form.

Creating an Instance from the Image

The next step is to create a VM instance from this image. From the sidebar on the left, navigate to

Compute → Compute Engine → VM instances

If this is the first instance you're adding to the project, click the Create instance button presented to you. Otherwise click the New instance button at the top-left of the interface.

You should now be faced with the Create a new instance form. For the most part, you can configure the instance however you like. The only field that we care about for now is labeled Boot disk; click the Change button to bring up the Boot disk menu. Navigate to the tab labeled Your image near the top of this menu. This should bring you to a list of GCE images created by you. Choose the image that you created in the previous section, and then click Select at the bottom of the menu; this should return you to the Create a new instance form. Once you are satisfied with your VM's initial configuration, click Create at the bottom of the form.

Logging into the VM

Now you should have a running VM with shipshape installed. Once the machine is up and running (this may take a few minutes) you can use ssh to obtain a remote shell. There are two ways of accomplishing this:

  1. Using GCE's builtin SSH tool
This is the easiest way to obtain a shell, as GCE will do most of the work
for you. Like so many times before, use the sidebar on the left to navigate
to

    Compute → Compute Engine → VM instances

From the list of instances, click on the name of the VM you created in the
previous section. This should bring you to a more detailed view of that VM.
Click on the **`SSH`** button at the top, and an `ssh` session should open
in a browser window.
  1. Using your own ssh client
*TODO*

Working with the VM

At this point you should have a remote shell on an Ubuntu 15.04 VM with shipshape ready to go. There is just one step remaining before you are ready to go -- you need to give yourself permission to use docker. Simply enter the following command (without the $) into your shell

$ sudo usermod -a -G docker ${USER?}

and then log out and back in.

Congratulations!

You are ready to start writing a Shipshape analyzer!

Creating an Instance with the gcloud tool

TODO