fog-openstack 0.2.0 → 0.2.1
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/lib/fog/identity/openstack.rb +7 -5
- data/lib/fog/identity/openstack/v2.rb +11 -2
- data/lib/fog/identity/openstack/v3.rb +11 -2
- data/lib/fog/openstack/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 9b30f652b4b6df666a43ce5d8a5df9e999062ea3
|
|
4
|
+
data.tar.gz: b0ef11fb9333c0987ae31ecead2c2f99ddf107a6
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: b96108935e442c7667530a689be9911a55a1c5d137b0072e322af3c47140e9fb1cdbae3f679838bda873169f719e84521bd08cef8b94ca9bf23d078f18e36e7d
|
|
7
|
+
data.tar.gz: 3b95ad280e133a331c803e7fd9b5daf3632085fa1ee0c05304cf9202e957a38a223c5eabe2752c4a81354483877ba6ff8aea8c45b81b885205b41e17e0f285f2
|
|
@@ -12,11 +12,13 @@ module Fog
|
|
|
12
12
|
# Will be removed in future after hard deprecation is enforced for a couple of releases
|
|
13
13
|
Fog::Logger.deprecation("An authentication URL including a version is deprecated")
|
|
14
14
|
case args[:openstack_auth_url]
|
|
15
|
-
when
|
|
16
|
-
args[:openstack_auth_url].gsub!(/\/v3(\/)
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
15
|
+
when /\/v3(\/)*.*$/
|
|
16
|
+
args[:openstack_auth_url].gsub!(/\/v3(\/)*.*$/, '')
|
|
17
|
+
args[:no_path_prefix] = true
|
|
18
|
+
'3'
|
|
19
|
+
when /\/v2(\.0)*(\/)*.*$/
|
|
20
|
+
args[:openstack_auth_url].gsub!(/\/v2(\.0)*(\/)*.*$/, '')
|
|
21
|
+
args[:no_path_prefix] = true
|
|
20
22
|
'2.0'
|
|
21
23
|
end
|
|
22
24
|
end
|
|
@@ -14,7 +14,7 @@ module Fog
|
|
|
14
14
|
:openstack_project_name, :openstack_project_id,
|
|
15
15
|
:openstack_project_domain, :openstack_user_domain, :openstack_domain_name,
|
|
16
16
|
:openstack_project_domain_id, :openstack_user_domain_id, :openstack_domain_id,
|
|
17
|
-
:openstack_identity_api_version
|
|
17
|
+
:openstack_identity_api_version, :no_path_prefix
|
|
18
18
|
|
|
19
19
|
model_path 'fog/identity/openstack/v2/models'
|
|
20
20
|
model :tenant
|
|
@@ -169,8 +169,17 @@ module Fog
|
|
|
169
169
|
end
|
|
170
170
|
|
|
171
171
|
class Real < Fog::Identity::OpenStack::Real
|
|
172
|
+
def initialize(args)
|
|
173
|
+
@path_prefix = if args[:no_path_prefix]
|
|
174
|
+
''
|
|
175
|
+
else
|
|
176
|
+
'v2.0'
|
|
177
|
+
end
|
|
178
|
+
super
|
|
179
|
+
end
|
|
180
|
+
|
|
172
181
|
def default_path_prefix
|
|
173
|
-
|
|
182
|
+
@path_prefix
|
|
174
183
|
end
|
|
175
184
|
|
|
176
185
|
def default_service_type
|
|
@@ -13,7 +13,7 @@ module Fog
|
|
|
13
13
|
:openstack_user_domain_id, :openstack_project_domain_id,
|
|
14
14
|
:openstack_api_key, :openstack_current_user_id, :openstack_userid, :openstack_username,
|
|
15
15
|
:current_user, :current_user_id, :current_tenant,
|
|
16
|
-
:provider, :openstack_identity_api_version, :openstack_cache_ttl
|
|
16
|
+
:provider, :openstack_identity_api_version, :openstack_cache_ttl, :no_path_prefix
|
|
17
17
|
|
|
18
18
|
model_path 'fog/identity/openstack/v3/models'
|
|
19
19
|
model :domain
|
|
@@ -142,8 +142,17 @@ module Fog
|
|
|
142
142
|
end
|
|
143
143
|
|
|
144
144
|
class Real < Fog::Identity::OpenStack::Real
|
|
145
|
+
def initialize(args)
|
|
146
|
+
@path_prefix = if args[:no_path_prefix]
|
|
147
|
+
''
|
|
148
|
+
else
|
|
149
|
+
'v3'
|
|
150
|
+
end
|
|
151
|
+
super
|
|
152
|
+
end
|
|
153
|
+
|
|
145
154
|
def default_path_prefix
|
|
146
|
-
|
|
155
|
+
@path_prefix
|
|
147
156
|
end
|
|
148
157
|
|
|
149
158
|
def default_service_type
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: fog-openstack
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Matt Darby
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2018-
|
|
11
|
+
date: 2018-09-02 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: fog-core
|