fog-openstack 1.0.10 → 1.0.11

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
  SHA256:
3
- metadata.gz: 9a8e252a230bee20d269d2d792ab05b8f99bae13717a9540cf2686d5fff8b5cd
4
- data.tar.gz: aca5c5940ba619c6a95ac6ca961d0497f0f363e27bc487683b69f0051b17d2ed
3
+ metadata.gz: 39e11cb8441eee8bdf906b567452056bd23a813ff1bad86311b36d21290e046e
4
+ data.tar.gz: 8253a9390f575e00c9fb1464292fa2506e900e0d1b342f7a744749359d94bd78
5
5
  SHA512:
6
- metadata.gz: 178b1d9f8c71816bb0bfb0880d29ce5a05a2de5fad03a55b2a14e35e70d66217cc2b98a83e781f6c9bbd66810396d470570a191f140f631fb8b555e92de2d269
7
- data.tar.gz: 2b5a5f10dcd085c61251dac698044b5a38f7f8ed7f2b35a3e59ebd3d4d590015f1884ecbbe5fb0d35603797cd8630de3b5e6d6314e1c4d2757338c825dd1dd78
6
+ metadata.gz: 9d31e9d1bd4557fb215069e6065dcc450334a0bf978caf288151f4d2b074578c5feeba44a51890804f9ea8fe5974f2209f9af96e114efe24203eeac4ce827eb7
7
+ data.tar.gz: 54036127d26fce6a4d9e7087216f6a36d2c3ae389ea314c988e66da885bc1531db44aedf1ee2ee39d1281063bfb23e12a62425fb3fae0161c5fa780ba27cf235
@@ -31,7 +31,7 @@ Gem::Specification.new do |spec|
31
31
  spec.add_development_dependency "mime-types-data"
32
32
  spec.add_development_dependency 'minitest'
33
33
  spec.add_development_dependency 'pry-byebug'
34
- spec.add_development_dependency 'rake', '~> 10.0'
34
+ spec.add_development_dependency 'rake', '>= 12.3.3'
35
35
  spec.add_development_dependency 'rubocop'
36
36
  spec.add_development_dependency 'shindo', '~> 0.3'
37
37
  spec.add_development_dependency 'vcr'
@@ -30,7 +30,7 @@ module Fog
30
30
  end
31
31
 
32
32
  def to_h(var)
33
- {var => send(var)}
33
+ {var => send(var).to_s}
34
34
  end
35
35
  end
36
36
 
@@ -54,7 +54,7 @@ module Fog
54
54
 
55
55
  response = @connection.request(
56
56
  params.merge(
57
- :headers => headers(params.delete(:headers)),
57
+ :headers => headers(params[:headers]),
58
58
  :path => "#{@path}/#{params[:path]}"
59
59
  )
60
60
  )
@@ -47,6 +47,7 @@ module Fog
47
47
  request :show_resource_metadata
48
48
  request :show_resource_schema
49
49
  request :show_resource_template
50
+ request :show_stack
50
51
  request :show_stack_details
51
52
  request :update_stack
52
53
  request :patch_stack
@@ -20,10 +20,11 @@ module Fog
20
20
  load_response(data, 'stacks')
21
21
  end
22
22
 
23
- # Deprecated
24
23
  def find_by_id(id)
25
- Fog::Logger.deprecation("#find_by_id(id) is deprecated, use #get(name, id) instead [light_black](#{caller.first})[/]")
26
- find { |stack| stack.id == id }
24
+ data = service.show_stack(id).body['stack']
25
+ new(data)
26
+ rescue Fog::OpenStack::Orchestration::NotFound
27
+ nil
27
28
  end
28
29
 
29
30
  def get(arg1, arg2 = nil)
@@ -0,0 +1,26 @@
1
+ module Fog
2
+ module OpenStack
3
+ class Orchestration
4
+ class Real
5
+ def show_stack(id)
6
+ request(
7
+ :method => 'GET',
8
+ :path => "stacks/#{id}",
9
+ :expects => 200
10
+ )
11
+ end
12
+ end
13
+
14
+ class Mock
15
+ def show_stack(_id)
16
+ stack = data[:stack].values
17
+
18
+ Excon::Response.new(
19
+ :body => {'stack' => stack},
20
+ :status => 200
21
+ )
22
+ end
23
+ end
24
+ end
25
+ end
26
+ end
@@ -1,5 +1,5 @@
1
1
  module Fog
2
2
  module OpenStack
3
- VERSION = '1.0.10'.freeze
3
+ VERSION = '1.0.11'.freeze
4
4
  end
5
5
  end
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: 1.0.10
4
+ version: 1.0.11
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matt Darby
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-09-18 00:00:00.000000000 Z
11
+ date: 2020-05-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: fog-core
@@ -140,16 +140,16 @@ dependencies:
140
140
  name: rake
141
141
  requirement: !ruby/object:Gem::Requirement
142
142
  requirements:
143
- - - "~>"
143
+ - - ">="
144
144
  - !ruby/object:Gem::Version
145
- version: '10.0'
145
+ version: 12.3.3
146
146
  type: :development
147
147
  prerelease: false
148
148
  version_requirements: !ruby/object:Gem::Requirement
149
149
  requirements:
150
- - - "~>"
150
+ - - ">="
151
151
  - !ruby/object:Gem::Version
152
- version: '10.0'
152
+ version: 12.3.3
153
153
  - !ruby/object:Gem::Dependency
154
154
  name: rubocop
155
155
  requirement: !ruby/object:Gem::Requirement
@@ -1060,6 +1060,7 @@ files:
1060
1060
  - lib/fog/openstack/orchestration/requests/show_resource_metadata.rb
1061
1061
  - lib/fog/openstack/orchestration/requests/show_resource_schema.rb
1062
1062
  - lib/fog/openstack/orchestration/requests/show_resource_template.rb
1063
+ - lib/fog/openstack/orchestration/requests/show_stack.rb
1063
1064
  - lib/fog/openstack/orchestration/requests/show_stack_details.rb
1064
1065
  - lib/fog/openstack/orchestration/requests/update_stack.rb
1065
1066
  - lib/fog/openstack/orchestration/requests/validate_template.rb