{"action":"created","issue":{"url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-common/issues/24","labels_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-common/issues/24/labels{/name}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-common/issues/24/comments","events_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-common/issues/24/events","html_url":"https://github.com/GoogleCloudPlatform/gcloud-common/issues/24","id":102870074,"number":24,"title":"Support for \"gcloud beta emulators datastore\"","user":{"login":"broady","id":24982,"avatar_url":"https://avatars.githubusercontent.com/u/24982?v=3","gravatar_id":"","url":"https://api.github.com/users/broady","html_url":"https://github.com/broady","followers_url":"https://api.github.com/users/broady/followers","following_url":"https://api.github.com/users/broady/following{/other_user}","gists_url":"https://api.github.com/users/broady/gists{/gist_id}","starred_url":"https://api.github.com/users/broady/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/broady/subscriptions","organizations_url":"https://api.github.com/users/broady/orgs","repos_url":"https://api.github.com/users/broady/repos","events_url":"https://api.github.com/users/broady/events{/privacy}","received_events_url":"https://api.github.com/users/broady/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-08-24T19:13:40Z","updated_at":"2015-08-24T19:57:34Z","closed_at":null,"body":"```\r\n$ gcloud beta emulators datastore env-init\r\nexport DATASTORE_HOST=http://localhost:8732\r\nexport DATASTORE_DATASET=cbro-scratch\r\n```\r\nSee this CL for the implementation to support these two environment variables in Go:\r\nhttps://code-review.googlesource.com/#/c/3350\r\n\r\nI believe this might already have (partial) support in Python?\r\n\r\n- [x] Python\r\n- [ ] Node\r\n- [ ] Golang\r\n- [ ] Ruby\r\n- [ ] Java\r\n\r\ncc @jonparrott"},"comment":{"url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-common/issues/comments/134358538","html_url":"https://github.com/GoogleCloudPlatform/gcloud-common/issues/24#issuecomment-134358538","issue_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-common/issues/24","id":134358538,"user":{"login":"dhermes","id":520669,"avatar_url":"https://avatars.githubusercontent.com/u/520669?v=3","gravatar_id":"","url":"https://api.github.com/users/dhermes","html_url":"https://github.com/dhermes","followers_url":"https://api.github.com/users/dhermes/followers","following_url":"https://api.github.com/users/dhermes/following{/other_user}","gists_url":"https://api.github.com/users/dhermes/gists{/gist_id}","starred_url":"https://api.github.com/users/dhermes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dhermes/subscriptions","organizations_url":"https://api.github.com/users/dhermes/orgs","repos_url":"https://api.github.com/users/dhermes/repos","events_url":"https://api.github.com/users/dhermes/events{/privacy}","received_events_url":"https://api.github.com/users/dhermes/received_events","type":"User","site_admin":false},"created_at":"2015-08-24T19:57:34Z","updated_at":"2015-08-24T19:57:34Z","body":"GAE is [done via services][1] provided by the Python runtime in GAE. The Golang equivalent is [`appengine.AppID`][2], but I'm not sure what idiomatic Go equivalent would be to checking if an import succeeded or failed and returning `nil` if the import failed.\r\n\r\nGCE is done by [hitting a specific URI][3] common to both GCE and EC2, but using a header which specifies that we want to get metadata for GCE.\r\n\r\n[1]: https://github.com/GoogleCloudPlatform/gcloud-python/blob/6df44a2c0f21bf5fb057f56d28e584dfe87b5c7b/gcloud/_helpers.py#L140-L150\r\n[2]: https://cloud.google.com/appengine/docs/go/reference#AppID\r\n[3]: https://github.com/GoogleCloudPlatform/gcloud-python/blob/6df44a2c0f21bf5fb057f56d28e584dfe87b5c7b/gcloud/_helpers.py#L170-L173"}}