fog-k5 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +11 -0
- data/lib/fog/k5/version.rb +1 -1
- data/lib/fog/storage/k5/real.rb +0 -3
- data/lib/fog/storage/k5/utils.rb +10 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e5ccec7dc892cbf7510dbca1a4096c4ada8e3d4f20b2f97e6d7e1ba5224b9f8a
|
4
|
+
data.tar.gz: b2e5a3137dcf344270d1e5997df65e5532240d85dc57a4c607870d70fe46c9c1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4b62b8d17c5786ad924c0cff07a39ee42d56a3514d121200d98a9253cc5357fb74cf929ff30180a1a2f541d35d95c2e5a78653f71d2121ea0962873c00eb6018
|
7
|
+
data.tar.gz: f826134c7f01e0ac60c2dbd2c15601aa0f533c9c167f509d31192b507b8ee1426c49c64456380546a422e7b4aae6fdb98d9b27237c81dd3b272718940107ff7b
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,16 @@
|
|
1
1
|
# Change Log
|
2
2
|
|
3
|
+
## [v0.1.2](https://github.com/blooper05/fog-k5/tree/v0.1.2) (2018-05-23)
|
4
|
+
[Full Changelog](https://github.com/blooper05/fog-k5/compare/v0.1.1...v0.1.2)
|
5
|
+
|
6
|
+
**Fixed bugs:**
|
7
|
+
|
8
|
+
- Authentication token is not updated [\#9](https://github.com/blooper05/fog-k5/issues/9)
|
9
|
+
|
10
|
+
**Merged pull requests:**
|
11
|
+
|
12
|
+
- 🐛 Use instance variables instead of Fog.credentials [\#10](https://github.com/blooper05/fog-k5/pull/10) ([blooper05](https://github.com/blooper05))
|
13
|
+
|
3
14
|
## [v0.1.1](https://github.com/blooper05/fog-k5/tree/v0.1.1) (2018-05-17)
|
4
15
|
[Full Changelog](https://github.com/blooper05/fog-k5/compare/v0.1.0...v0.1.1)
|
5
16
|
|
data/lib/fog/k5/version.rb
CHANGED
data/lib/fog/storage/k5/real.rb
CHANGED
@@ -22,13 +22,10 @@ module Fog
|
|
22
22
|
@k5_domain_name = options[:k5_domain_name]
|
23
23
|
@k5_user_name = options[:k5_user_name]
|
24
24
|
@k5_user_password = options[:k5_user_password]
|
25
|
-
|
26
|
-
refresh_auth_token_if_expired
|
27
25
|
end
|
28
26
|
|
29
27
|
def params
|
30
28
|
{
|
31
|
-
headers: { 'X-Auth-Token' => @k5_auth_token },
|
32
29
|
path_prefix: "#{K5_STORAGE_URL_VERSION}/AUTH_#{@k5_project_id}",
|
33
30
|
query: { format: :json },
|
34
31
|
}
|
data/lib/fog/storage/k5/utils.rb
CHANGED
@@ -2,16 +2,24 @@ module Fog
|
|
2
2
|
module Storage
|
3
3
|
class K5
|
4
4
|
module Utils
|
5
|
+
include Fog::K5::Shared
|
6
|
+
|
5
7
|
def request(params)
|
6
|
-
|
8
|
+
refresh_auth_token_if_expired
|
9
|
+
|
10
|
+
escaped_params = escape(add_auth_header(params))
|
7
11
|
parse(@connection.request(escaped_params))
|
8
12
|
end
|
9
13
|
|
10
14
|
private
|
11
15
|
|
16
|
+
def add_auth_header(params)
|
17
|
+
params.merge(headers: { 'X-Auth-Token' => @k5_auth_token })
|
18
|
+
end
|
19
|
+
|
12
20
|
def escape(params)
|
13
21
|
middlewares = Excon.defaults[:middlewares] +
|
14
|
-
|
22
|
+
[Excon::Middleware::EscapePath]
|
15
23
|
params.merge(middlewares: middlewares)
|
16
24
|
end
|
17
25
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fog-k5
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- blooper05
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-05-
|
11
|
+
date: 2018-05-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: fog-core
|