| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -301,6 +301,13 @@ def generate_signed_url(credentials, resource, expiration, | |||
| 301 | 301 | content_type=None): | |
| 302 | 302 | """Generate signed URL to provide query-string auth'n to a resource. | |
| 303 | 303 | ||
| 304 | + .. note:: | ||
| 305 | + If you are on Google Compute Engine, you can't generate a signed URL. | ||
| 306 | + Follow https://github.com/GoogleCloudPlatform/gcloud-python/issues/922 | ||
| 307 | + for updates on this. If you'd like to be able to generate a signed URL | ||
| 308 | + from GCE, you can use a standard service account from a JSON file | ||
| 309 | + rather than a GCE service account. | ||
| 310 | + | ||
| 304 | 311 | :type credentials: :class:`oauth2client.appengine.AppAssertionCredentials` | |
| 305 | 312 | :param credentials: Credentials object with an associated private key to | |
| 306 | 313 | sign text. | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -157,6 +157,14 @@ def generate_signed_url(self, expiration, method='GET', | |||
| 157 | 157 | client=None, credentials=None): | |
| 158 | 158 | """Generates a signed URL for this blob. | |
| 159 | 159 | ||
| 160 | + .. note:: | ||
| 161 | + If you are on Google Compute Engine, you can't generate a signed URL. | ||
| 162 | + Follow | ||
| 163 | + https://github.com/GoogleCloudPlatform/gcloud-python/issues/922 | ||
| 164 | + for updates on this. If you'd like to be able to generate a signed | ||
| 165 | + URL from GCE, you can use a standard service account from a JSON | ||
| 166 | + file rather than a GCE service account. | ||
| 167 | + | ||
| 160 | 168 | If you have a blob that you want to allow access to for a set | |
| 161 | 169 | amount of time, you can use this method to generate a URL that | |
| 162 | 170 | is only valid within a certain time period. | |
| Back | FazBrowse Home | New Git URL |
0 commit comments