google-cloud-storage 1.29.2 → 1.30.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +13 -0
- data/lib/google/cloud/storage/bucket.rb +32 -19
- data/lib/google/cloud/storage/version.rb +1 -1
- metadata +19 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d3b78945de5adc36366ded346357d71f954327a48b11d9d909ad5b8443f51c95
|
4
|
+
data.tar.gz: adcc876f70b87130ca732a591a9f1d6aa278e03a0356ea012620f30650c3b25e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e46be5fe50420e4a674add04d12a06243dba3438aafedc9356246ac8e5fa66aa0db547d9264a70b940cd46133aed1b7256cdad02397c93b0eeb73d312fffdd48
|
7
|
+
data.tar.gz: 0a89f487726406d8865b1c675d43f1153e3cf78d0e5b8df1ebc4eb1f09a051f9dd45c328503d500dda6aee4bcd60c3693104d0371755154263eb52ccceaf3b1b
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,18 @@
|
|
1
1
|
# Release History
|
2
2
|
|
3
|
+
### 1.30.0 / 2021-01-13
|
4
|
+
|
5
|
+
#### Features
|
6
|
+
|
7
|
+
* Replace google-api-client with specific client gems
|
8
|
+
* Remove google-api-client
|
9
|
+
* Add google-apis-iamcredentials_v1
|
10
|
+
* Add google-apis-storage_v1
|
11
|
+
|
12
|
+
#### Documentation
|
13
|
+
|
14
|
+
* Update Bucket#generate_signed_post_policy_v4 documentation
|
15
|
+
|
3
16
|
### 1.29.2 / 2020-12-14
|
4
17
|
|
5
18
|
#### Bug Fixes
|
@@ -1647,8 +1647,8 @@ module Google
|
|
1647
1647
|
end
|
1648
1648
|
|
1649
1649
|
##
|
1650
|
-
# Generate a PostObject that includes the fields and
|
1651
|
-
# upload objects via
|
1650
|
+
# Generate a PostObject that includes the fields and URL to
|
1651
|
+
# upload objects via HTML forms.
|
1652
1652
|
#
|
1653
1653
|
# Generating a PostObject requires service account credentials,
|
1654
1654
|
# either by connecting with a service account when calling
|
@@ -1694,7 +1694,7 @@ module Google
|
|
1694
1694
|
# Proc should return a signature created using a RPC call to the
|
1695
1695
|
# [Service Account Credentials signBlob](https://cloud.google.com/iam/docs/reference/credentials/rest/v1/projects.serviceAccounts/signBlob)
|
1696
1696
|
# method as shown in the example below.
|
1697
|
-
# @return [PostObject] An object containing the URL, fields, and values needed to upload files via
|
1697
|
+
# @return [PostObject] An object containing the URL, fields, and values needed to upload files via HTML forms.
|
1698
1698
|
#
|
1699
1699
|
# @raise [SignedUrlUnavailable] If the service account credentials
|
1700
1700
|
# are missing. Service account credentials are acquired by following the
|
@@ -1817,10 +1817,14 @@ module Google
|
|
1817
1817
|
end
|
1818
1818
|
|
1819
1819
|
##
|
1820
|
-
# Generate a PostObject that includes the fields and
|
1821
|
-
# upload objects via
|
1820
|
+
# Generate a `PostObject` that includes the fields and URL to
|
1821
|
+
# upload objects via HTML forms. The resulting `PostObject` is
|
1822
|
+
# based on a policy document created from the method arguments.
|
1823
|
+
# This policy provides authorization to ensure that the HTML
|
1824
|
+
# form can upload files into the bucket. See [Signatures -
|
1825
|
+
# Policy document](https://cloud.google.com/storage/docs/authentication/signatures#policy-document).
|
1822
1826
|
#
|
1823
|
-
# Generating a PostObject requires service account credentials,
|
1827
|
+
# Generating a `PostObject` requires service account credentials,
|
1824
1828
|
# either by connecting with a service account when calling
|
1825
1829
|
# {Google::Cloud.storage}, or by passing in the service account
|
1826
1830
|
# `issuer` and `signing_key` values. Although the private key can
|
@@ -1833,6 +1837,8 @@ module Google
|
|
1833
1837
|
# steps in [Service Account Authentication](
|
1834
1838
|
# https://cloud.google.com/iam/docs/service-accounts).
|
1835
1839
|
#
|
1840
|
+
# @see https://cloud.google.com/storage/docs/authentication/signatures#policy-document Signatures -
|
1841
|
+
# Policy document
|
1836
1842
|
# @see https://cloud.google.com/storage/docs/xml-api/post-object
|
1837
1843
|
#
|
1838
1844
|
# @param [String] path Path to the file in Google Cloud Storage.
|
@@ -1856,9 +1862,14 @@ module Google
|
|
1856
1862
|
# method as shown in the example below.
|
1857
1863
|
# @param [Integer] expires The number of seconds until the URL expires.
|
1858
1864
|
# The default is 604800 (7 days).
|
1859
|
-
# @param [Hash] fields User-supplied form fields such as `acl`,
|
1865
|
+
# @param [Hash{String => String}] fields User-supplied form fields such as `acl`,
|
1860
1866
|
# `cache-control`, `success_action_status`, and `success_action_redirect`.
|
1861
|
-
#
|
1867
|
+
# Optional. See [Upload an object with HTML forms - Form
|
1868
|
+
# fields](https://cloud.google.com/storage/docs/xml-api/post-object-forms#form_fields).
|
1869
|
+
# @param [Array<Hash{String => String}|Array<String>>] conditions An array of
|
1870
|
+
# policy conditions that every upload must satisfy. For example:
|
1871
|
+
# `[["eq", "$Content-Type", "image/jpeg"]]`. Optional. See [Signatures - Policy
|
1872
|
+
# document](https://cloud.google.com/storage/docs/authentication/signatures#policy-document).
|
1862
1873
|
# @param [String] scheme The URL scheme. The default value is `HTTPS`.
|
1863
1874
|
# @param [Boolean] virtual_hosted_style Whether to use a virtual hosted-style
|
1864
1875
|
# hostname, which adds the bucket into the host portion of the URI rather
|
@@ -1871,12 +1882,12 @@ module Google
|
|
1871
1882
|
# Cloud Load Balancer which routes to a bucket you own, e.g.
|
1872
1883
|
# `my-load-balancer-domain.tld`.
|
1873
1884
|
#
|
1874
|
-
# @return [PostObject] An object containing the URL, fields, and values needed to
|
1885
|
+
# @return [PostObject] An object containing the URL, fields, and values needed to
|
1886
|
+
# upload files via HTML forms.
|
1875
1887
|
#
|
1876
|
-
# @raise [SignedUrlUnavailable] If the service account credentials
|
1877
|
-
#
|
1878
|
-
#
|
1879
|
-
# https://cloud.google.com/iam/docs/service-accounts).
|
1888
|
+
# @raise [SignedUrlUnavailable] If the service account credentials are missing.
|
1889
|
+
# Service account credentials are acquired by following the steps in [Service
|
1890
|
+
# Account Authentication](https://cloud.google.com/iam/docs/service-accounts).
|
1880
1891
|
#
|
1881
1892
|
# @example
|
1882
1893
|
# require "google/cloud/storage"
|
@@ -1886,8 +1897,9 @@ module Google
|
|
1886
1897
|
# bucket = storage.bucket "my-todo-app"
|
1887
1898
|
#
|
1888
1899
|
# conditions = [["starts-with", "$acl","public"]]
|
1889
|
-
# post = bucket.generate_signed_post_policy_v4 "avatars/heidi/400x400.png",
|
1890
|
-
#
|
1900
|
+
# post = bucket.generate_signed_post_policy_v4 "avatars/heidi/400x400.png",
|
1901
|
+
# expires: 10,
|
1902
|
+
# conditions: conditions
|
1891
1903
|
#
|
1892
1904
|
# post.url #=> "https://storage.googleapis.com/my-todo-app/"
|
1893
1905
|
# post.fields["key"] #=> "my-todo-app/avatars/heidi/400x400.png"
|
@@ -1928,10 +1940,11 @@ module Google
|
|
1928
1940
|
#
|
1929
1941
|
# bucket = storage.bucket "my-todo-app"
|
1930
1942
|
# conditions = [["starts-with", "$acl","public"]]
|
1931
|
-
# post = bucket.generate_signed_post_policy_v4
|
1932
|
-
#
|
1933
|
-
#
|
1934
|
-
#
|
1943
|
+
# post = bucket.generate_signed_post_policy_v4 "avatars/heidi/400x400.png",
|
1944
|
+
# expires: 10,
|
1945
|
+
# conditions: conditions,
|
1946
|
+
# issuer: issuer,
|
1947
|
+
# signer: signer
|
1935
1948
|
#
|
1936
1949
|
# post.url #=> "https://storage.googleapis.com/my-todo-app/"
|
1937
1950
|
# post.fields["key"] #=> "my-todo-app/avatars/heidi/400x400.png"
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: google-cloud-storage
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.30.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mike Moore
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2021-01-13 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: google-cloud-core
|
@@ -26,19 +26,33 @@ dependencies:
|
|
26
26
|
- !ruby/object:Gem::Version
|
27
27
|
version: '1.2'
|
28
28
|
- !ruby/object:Gem::Dependency
|
29
|
-
name: google-
|
29
|
+
name: google-apis-iamcredentials_v1
|
30
30
|
requirement: !ruby/object:Gem::Requirement
|
31
31
|
requirements:
|
32
32
|
- - "~>"
|
33
33
|
- !ruby/object:Gem::Version
|
34
|
-
version: '0.
|
34
|
+
version: '0.1'
|
35
35
|
type: :runtime
|
36
36
|
prerelease: false
|
37
37
|
version_requirements: !ruby/object:Gem::Requirement
|
38
38
|
requirements:
|
39
39
|
- - "~>"
|
40
40
|
- !ruby/object:Gem::Version
|
41
|
-
version: '0.
|
41
|
+
version: '0.1'
|
42
|
+
- !ruby/object:Gem::Dependency
|
43
|
+
name: google-apis-storage_v1
|
44
|
+
requirement: !ruby/object:Gem::Requirement
|
45
|
+
requirements:
|
46
|
+
- - "~>"
|
47
|
+
- !ruby/object:Gem::Version
|
48
|
+
version: '0.1'
|
49
|
+
type: :runtime
|
50
|
+
prerelease: false
|
51
|
+
version_requirements: !ruby/object:Gem::Requirement
|
52
|
+
requirements:
|
53
|
+
- - "~>"
|
54
|
+
- !ruby/object:Gem::Version
|
55
|
+
version: '0.1'
|
42
56
|
- !ruby/object:Gem::Dependency
|
43
57
|
name: googleauth
|
44
58
|
requirement: !ruby/object:Gem::Requirement
|