You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jclouds.apache.org by na...@apache.org on 2015/05/04 14:22:00 UTC

jclouds-site git commit: updating google guide

Repository: jclouds-site
Updated Branches:
  refs/heads/master 5e487cf2f -> 7ba3e07f2


updating google guide


Project: http://git-wip-us.apache.org/repos/asf/jclouds-site/repo
Commit: http://git-wip-us.apache.org/repos/asf/jclouds-site/commit/7ba3e07f
Tree: http://git-wip-us.apache.org/repos/asf/jclouds-site/tree/7ba3e07f
Diff: http://git-wip-us.apache.org/repos/asf/jclouds-site/diff/7ba3e07f

Branch: refs/heads/master
Commit: 7ba3e07f24fe746cbf7765e137ff81cb295d0af7
Parents: 5e487cf
Author: Daniel Broudy <br...@google.com>
Authored: Fri May 1 18:28:00 2015 -0700
Committer: Ignasi Barrera <na...@apache.org>
Committed: Mon May 4 12:45:34 2015 +0200

----------------------------------------------------------------------
 guides/google.md | 35 ++++++++++++++++++++++-------------
 1 file changed, 22 insertions(+), 13 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/jclouds-site/blob/7ba3e07f/guides/google.md
----------------------------------------------------------------------
diff --git a/guides/google.md b/guides/google.md
index 5281aef..81ceb92 100644
--- a/guides/google.md
+++ b/guides/google.md
@@ -7,18 +7,32 @@ permalink: /guides/google/
 ## <a id="intro"></a>Introduction
 This guide helps you to get started with [Google Cloud Platform](https://cloud.google.com/) development using jclouds.
 
-Currently, [Google Compute Engine](https://developers.google.com/compute/) is covered. This is a [compute service](http://jclouds.apache.org/start/compute/) that allows you to run vitual machines on Google's infrastructure.
+Currently, [Google Compute Engine](https://developers.google.com/compute/) is covered. This is a [compute service](http://jclouds.apache.org/start/compute/) that allows you to run vitual machines on Google's infrastructure. There is also an implementation of the [blob store](http://jclouds.apache.org/start/blobstore/) abstraction for managing key-value storage.
 
-This guide assumes you have a Google Cloud project. If you do not have a project yet, you can sign up via the [Developer Console](https://console.developers.google.com/). For GCE, you need to set up billing.
+Working with the Google Cloud Platform requires a project. If you do not have a project yet, you can sign up via the [Developer Console](https://console.developers.google.com/). There is a free trial availible [here](https://cloud.google.com/free-trial/).
+
+## <a id="examples"></a>Running examples
+A great starting point for using jclouds on GCE is to run the examples provided on [github](https://github.com/jclouds/jclouds-examples).
+
+Important Setup
+
+  * Create a project on the [Developer Console](https://console.developers.google.com/) (instruction availible [here](https://developers.google.com/console/help/#creatingdeletingprojects))
+  * Go to the [Developer Console](https://console.developers.google.com/) and choose your project.
+  * Enable the Google Compute Engine API under APIs & auth > APIs
+  * Create a service account under APIs & auth > Credentials > Create new Client ID and download the Json key. This is described more throughly below under Authentication.
+
+Once you have completed the setup, checkout the [jclouds-examples](https://github.com/jclouds/jclouds-examples) repository and look at either [compute-basic](https://github.com/jclouds/jclouds-examples/tree/master/compute-basics) for an example of using the compute service abstraction or [google-lb](https://github.com/jclouds/jclouds-examples/tree/master/google-lb) for an example of using the GCE api directly.
+
+If you are having trouble feel free to [reach out](https://jclouds.apache.org/community/).
 
 ## <a id="auth"></a>Authentication
 Google Cloud Platform uses OAuth2 which gives a variety of choices how to authenticate:
 
 1. You can ask a user for consent to perform operations in their name.
 2. You can create a service account and authenticate using its private key.
-3. Unless configured otherwise, programs running on a GCE instance can perform operations as the project's default service account ([documentation](https://developers.google.com/compute/docs/authentication)).
+3. Unless configured otherwise, programs running on a GCE instance can perform operations as the project's default service account ([documentation](https://cloud.google.com/compute/docs/authentication)).
 
-You can find all the details in [the documentation](https://developers.google.com/accounts/docs/OAuth2), while in these examples we will focus on option 2: service accounts.
+You can find all the details in [the documentation](https://developers.google.com/accounts/docs/OAuth2), in the jclouds-examples repository we focus on option 2: service accounts.
 
 To create a new service account:
 
@@ -26,13 +40,8 @@ To create a new service account:
   * Choose your project.
   * Choose API & auth > Credentials.
   * Click "Create new Client ID".
-  * Select "Service account" and click "Create service ID".
-  * Details of the new service account will be displayed. You will also be able to download the private key for this account, which you will need for authentication. Make a note of the service account email address - you will need it to use the account.
-  * To keep the examples simple, we use private keys without passwords. It might be something you will not do in a production environment, but to create a private key without a password for use in the examples, run: `openssl pkcs12 -in {downloaded_file}.p12 -nodes -out gcp-example.pem  -passin pass:notasecret`.
-
-## <a id="examples"></a>Running examples
-A good starting point for using GCE vis jclouds is to run [examples programs](https://github.com/jclouds/jclouds-examples/tree/master/google/src/main/java/org/jclouds/examples/google/computeengine). For this, download the [jclouds-example](https://github.com/jclouds/jclouds-examples) repository and build the "google" Maven project. Each example can be run by passing the service account email as the first parameter and the path to the gcp-example.pem file (created by removing the password from the *.p12 file by the command above) as the second.
-
-For example, running [org.jclouds.examples.google.computeengine.CreateServer](https://github.com/jclouds/jclouds-examples/blob/master/google/src/main/java/org/jclouds/examples/google/computeengine/CreateServer.java) will create a new virtual machine running Debian (and its persistent disk). Open the [Developer Console](https://console.developers.google.com/) and navigate to your project and choose "Compute Engine" to see it. You can use gcutil from Google Cloud SDK to ssh to that machine - see the SSH button on that page.
+  * Select "Service account" and click "Create Client ID".
+  * Details of the new service account will be displayed.
+  * Download a JSON key for a service account by clicking Generate new JSON key. JSON keys are used for authentication when running jclouds on GCE. Make a note of the service account email address - this is the identity that goes with the key.
 
-If anything failed, you can see the operation status on Compute Engine > Operations page of the [Developer Console](https://console.developers.google.com/).
+If you are having trouble feel free to [reach out](https://jclouds.apache.org/community/).
\ No newline at end of file