fog-google 0.4.0 → 0.4.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 8a4aac1948c7ed0d3f7248b351c6140f9a08b3de
4
- data.tar.gz: 4db3c146ba5402041ce46aac9b72504977b9a361
3
+ metadata.gz: 92c9efd9ddab995f14a3f4eeb4ffca1ba7ee6ccc
4
+ data.tar.gz: 28ea5908d53b53f5b893c1d235503083989e6aa3
5
5
  SHA512:
6
- metadata.gz: 079ccb37684b05947be1e6c8637d2955484202744e2ad43d72890e1edeec3e70e386238271cfc003bd000b829f0ff42d03e4fdf74380fb7ff21a79361c685b40
7
- data.tar.gz: f41c1a0bbcee5788678ff0610f1dc886af968a7508c9a76cf48cbbcfb01d9e6cf15c413becebec2d4e1c022b5eb06f2b88ec64b7a0d0e25021c827ecde0a71e3
6
+ metadata.gz: 6ddc1cd98ae4127f6c8ea549bbceee964c6cc15cb8e8f30def296bb7764a4f42455fc9c97f4fe1876e901644b9ba9227843566fb68f9cb38847d5e816c72fc55
7
+ data.tar.gz: 5c9ef2418309ff8ff900717fc2ea9650429e465a051aadec83b7809b0a6aebc1ff296bad96c788b0cba1679999f7de4ca557ccc9942ac95f1896e27569eb92fb
@@ -1,5 +1,5 @@
1
1
  module Fog
2
2
  module Google
3
- VERSION = "0.4.0".freeze
3
+ VERSION = "0.4.1".freeze
4
4
  end
5
5
  end
@@ -32,7 +32,7 @@ module Fog
32
32
  elsif data.is_a? String
33
33
  data = StringIO.new(data)
34
34
  mime_type = "text/plain"
35
- elsif data.is_a? File
35
+ elsif data.is_a? ::File
36
36
  mime_type = Fog::Storage.parse_data(data)[:headers]["Content-Type"]
37
37
  end
38
38
 
@@ -8,6 +8,9 @@ module Fog
8
8
  # * bucket_name<~String> - Name of bucket containing object
9
9
  # * object_name<~String> - Name of object to get expiring url for
10
10
  # * expires<~Time> - An expiry time for this url
11
+ # * If you want a file to be public you should to add { 'x-goog-acl' => 'public-read' } to headers
12
+ # And then call for example: curl -H "x-goog-acl:public-read" "signed url"
13
+ #
11
14
  #
12
15
  # ==== Returns
13
16
  # * response<~Excon::Response>:
@@ -16,7 +19,7 @@ module Fog
16
19
  # ==== See Also
17
20
  # https://cloud.google.com/storage/docs/access-control#Signed-URLs
18
21
  #
19
- def put_object_url(bucket_name, object_name, headers = {})
22
+ def put_object_url(bucket_name, object_name, expires, headers = {})
20
23
  raise ArgumentError.new("bucket_name is required") unless bucket_name
21
24
  raise ArgumentError.new("object_name is required") unless object_name
22
25
  https_url({
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fog-google
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 0.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nat Welch
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2016-08-30 00:00:00.000000000 Z
14
+ date: 2016-10-11 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: fog-core