From 9b5955b918ffc0f48c757ed397bb233316a6a66a Mon Sep 17 00:00:00 2001 From: Stephen Sawchuk Date: Wed, 19 Nov 2014 15:49:23 -0500 Subject: [PATCH 1/2] export auth to FAQ on wiki --- README.md | 46 +++++++++++++--------------------------------- 1 file changed, 13 insertions(+), 33 deletions(-) diff --git a/README.md b/README.md index 48729859d48..b2415d63ecd 100644 --- a/README.md +++ b/README.md @@ -7,6 +7,8 @@ * [Homepage][gcloud-homepage] * [API Documentation][gcloud-docs] +* [Frequently Asked Questions][wiki-faq] +* [Examples][wiki-examples] This client supports the following Google Cloud Platform services: @@ -15,39 +17,18 @@ This client supports the following Google Cloud Platform services: * [Google Cloud Storage][cloud-storage] * [Google Cloud Pub/Sub][cloud-pubsub] (Alpha) -If you need support for other Google APIs, check out the [Google Node.js API Client library][googleapis]. -## Quick Start +## Getting Started ```sh $ npm install --save gcloud ``` -## Examples +:warning: **All `gcloud` service APIs require authorization details for your project.** -- [TodoMVC backend using gcloud-node][gcloud-todos] +Instructions on where to find these are available if you are [running your application on Google Compute Engine][wiki-faq-gce], or [running it elsewhere][wiki-faq-elsewhere]. -## Authorization - -### On Google Compute Engine - -If you are running this client on Google Compute Engine, we handle authorization for you with no configuration. You just need to make sure that when you [set up the GCE instance][gce-how-to], you add the correct scopes for the APIs you want to access. - -### Elsewhere - -If you are not running this client on Google Compute Engine, you need a Google Developers service account. To create a service account: - -1. Visit the [Google Developers Console][dev-console]. -2. Create a new project or click on an existing project. -3. Navigate to **APIs & auth** > **APIs section** and turn on the following APIs (you may need to enable billing in order to use these services): - * Google Cloud Datastore API - * Google Cloud Storage - * Google Cloud Storage JSON API -4. Navigate to **APIs & auth** > **Credentials** and then: - * If you want to use a new service account, click on **Create new Client ID** and select **Service account**. After the account is created, you will be prompted to download the JSON key file that the library uses to authorize your requests. - * If you want to generate a new key for an existing service account, click on **Generate new JSON key** and download the JSON key file. - -## Google BigQuery +### Google BigQuery Analyze Big Data in the cloud with [Google BigQuery][cloud-bigquery] ([docs][cloud-bigquery-docs]) . Run fast, SQL-like queries against multi-terabyte datasets in seconds. Scalable and easy to use, BigQuery gives you real-time insights about your data. @@ -87,7 +68,7 @@ bigquery.job('job-id') .pipe(process.stdout); ``` -## Google Cloud Datastore +### Google Cloud Datastore [Google Cloud Datastore][cloud-datastore] ([docs][cloud-datastore-docs]) is a fully managed, schemaless database for storing non-relational data. Cloud Datastore automatically scales with your users and supports ACID transactions, high availability of reads and writes, strong consistency for reads and ancestor queries, and eventual consistency for all other queries. @@ -115,7 +96,7 @@ dataset.get(dataset.key(['Product', 'Computer']), function(err, entity) { }); ``` -## Google Cloud Storage +### Google Cloud Storage [Google Cloud Storage][cloud-storage] ([docs][cloud-storage-docs]) allows you to store data on Google infrastructure with very high reliability, performance and availability, and can be used to distribute large data objects to users via direct download. @@ -150,7 +131,7 @@ fs.createReadStream('/local/file.txt').pipe(bucket.file('file.txt').createWriteS bucket.file('photo.jpg').createReadStream().pipe(fs.createWriteStream('/local/photo.jpg')); ``` -## Google Cloud Pub/Sub (Alpha) +### Google Cloud Pub/Sub (Alpha) > Google Cloud Pub/Sub is in **Alpha status**. As a result, it might change in backward-incompatible ways and is not recommended for production use. It is not subject to any SLA or deprecation policy. @@ -210,12 +191,11 @@ Apache 2.0 - See [COPYING](COPYING) for more information. [gcloud-datastore-docs]: https://googlecloudplatform.github.io/gcloud-node/#/docs/datastore [gcloud-pubsub-docs]: https://googlecloudplatform.github.io/gcloud-node/#/docs/pubsub [gcloud-storage-docs]: https://googlecloudplatform.github.io/gcloud-node/#/docs/storage -[gcloud-todos]: https://github.com/GoogleCloudPlatform/gcloud-node-todos - -[dev-console]: https://console.developers.google.com/project -[gce-how-to]: https://developers.google.com/compute/docs/authentication#using -[googleapis]: https://github.com/google/google-api-nodejs-client +[wiki-faq]: https://github.com/GoogleCloudPlatform/wiki/Frequently-Asked-Questions +[wiki-examples]: https://github.com/GoogleCloudPlatform/wiki/Examples +[wiki-faq-gce]: https://github.com/GoogleCloudPlatform/wiki/Frequently-Asked-Questions#how-do-i-use-gcloud-with-google-compute-engine] +[wiki-faq-elsewhere]: https://github.com/GoogleCloudPlatform/wiki/Frequently-Asked-Questions#im-not-using-compute-engine-what-do-i-need-to-do] [cloud-bigquery]: https://cloud.google.com/bigquery [cloud-bigquery-docs]: https://cloud.google.com/bigquery/what-is-bigquery From fb7d7c37721866c014804b69ec246f3a77f1bfa1 Mon Sep 17 00:00:00 2001 From: Stephen Sawchuk Date: Wed, 19 Nov 2014 15:52:56 -0500 Subject: [PATCH 2/2] promote heading levels of services --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index b2415d63ecd..3bb860c842f 100644 --- a/README.md +++ b/README.md @@ -28,7 +28,7 @@ $ npm install --save gcloud Instructions on where to find these are available if you are [running your application on Google Compute Engine][wiki-faq-gce], or [running it elsewhere][wiki-faq-elsewhere]. -### Google BigQuery +## Google BigQuery Analyze Big Data in the cloud with [Google BigQuery][cloud-bigquery] ([docs][cloud-bigquery-docs]) . Run fast, SQL-like queries against multi-terabyte datasets in seconds. Scalable and easy to use, BigQuery gives you real-time insights about your data. @@ -68,7 +68,7 @@ bigquery.job('job-id') .pipe(process.stdout); ``` -### Google Cloud Datastore +## Google Cloud Datastore [Google Cloud Datastore][cloud-datastore] ([docs][cloud-datastore-docs]) is a fully managed, schemaless database for storing non-relational data. Cloud Datastore automatically scales with your users and supports ACID transactions, high availability of reads and writes, strong consistency for reads and ancestor queries, and eventual consistency for all other queries. @@ -96,7 +96,7 @@ dataset.get(dataset.key(['Product', 'Computer']), function(err, entity) { }); ``` -### Google Cloud Storage +## Google Cloud Storage [Google Cloud Storage][cloud-storage] ([docs][cloud-storage-docs]) allows you to store data on Google infrastructure with very high reliability, performance and availability, and can be used to distribute large data objects to users via direct download. @@ -131,7 +131,7 @@ fs.createReadStream('/local/file.txt').pipe(bucket.file('file.txt').createWriteS bucket.file('photo.jpg').createReadStream().pipe(fs.createWriteStream('/local/photo.jpg')); ``` -### Google Cloud Pub/Sub (Alpha) +## Google Cloud Pub/Sub (Alpha) > Google Cloud Pub/Sub is in **Alpha status**. As a result, it might change in backward-incompatible ways and is not recommended for production use. It is not subject to any SLA or deprecation policy.