Class: Fog::Orchestration::OpenStack::Stack
- Inherits:
-
Fog::OpenStack::Model
- Object
- Model
- Fog::OpenStack::Model
- Fog::Orchestration::OpenStack::Stack
- Defined in:
- lib/fog/openstack/models/orchestration/stack.rb
Instance Attribute Summary
Attributes inherited from Fog::OpenStack::Model
Instance Method Summary collapse
- #abandon ⇒ Object
-
#create ⇒ Object
Deprecated.
- #delete ⇒ Object (also: #destroy)
- #details ⇒ Object
- #events(options = {}) ⇒ Object
- #patch(options = {}) ⇒ Object
- #resources(options = {}) ⇒ Object
- #save(options = {}) ⇒ Object
- #template ⇒ Object
-
#template=(content) ⇒ Object
Deprecated.
-
#template_url ⇒ Object
Deprecated.
-
#template_url=(url) ⇒ Object
Deprecated.
-
#timeout_in_minutes ⇒ Object
Deprecated.
-
#timeout_in_minutes=(minutes) ⇒ Object
Deprecated.
-
#update ⇒ Object
Deprecated.
Methods inherited from Fog::OpenStack::Model
Constructor Details
This class inherits a constructor from Fog::OpenStack::Model
Instance Method Details
#abandon ⇒ Object
64 65 66 |
# File 'lib/fog/openstack/models/orchestration/stack.rb', line 64 def abandon service.abandon_stack(self) end |
#create ⇒ Object
Deprecated
25 26 27 28 29 |
# File 'lib/fog/openstack/models/orchestration/stack.rb', line 25 def create Fog::Logger.deprecation("#create is deprecated, use #save(options) instead [light_black](#{caller.first})[/]") requires :stack_name service.stacks.create() end |
#delete ⇒ Object Also known as: destroy
43 44 45 |
# File 'lib/fog/openstack/models/orchestration/stack.rb', line 43 def delete service.delete_stack(self) end |
#details ⇒ Object
48 49 50 |
# File 'lib/fog/openstack/models/orchestration/stack.rb', line 48 def details @details ||= service.stacks.get(self.stack_name, self.id) end |
#events(options = {}) ⇒ Object
56 57 58 |
# File 'lib/fog/openstack/models/orchestration/stack.rb', line 56 def events(={}) @events ||= service.events.all(self, ) end |
#patch(options = {}) ⇒ Object
38 39 40 41 |
# File 'lib/fog/openstack/models/orchestration/stack.rb', line 38 def patch( = {}) requires :stack_name service.patch_stack(self, ).body['stack'] end |
#resources(options = {}) ⇒ Object
52 53 54 |
# File 'lib/fog/openstack/models/orchestration/stack.rb', line 52 def resources(={}) @resources ||= service.resources.all({:stack => self}.merge()) end |
#save(options = {}) ⇒ Object
16 17 18 19 20 21 22 |
# File 'lib/fog/openstack/models/orchestration/stack.rb', line 16 def save(={}) if persisted? service.update_stack(self, .merge()).body['stack'] else service.stacks.create(.merge()) end end |
#template ⇒ Object
60 61 62 |
# File 'lib/fog/openstack/models/orchestration/stack.rb', line 60 def template @template ||= service.templates.get(self) end |
#template=(content) ⇒ Object
Deprecated
82 83 84 85 |
# File 'lib/fog/openstack/models/orchestration/stack.rb', line 82 def template=(content) Fog::Logger.deprecation("#template=(content) is deprecated, use it in options for #save(options) instead [light_black](#{caller.first})[/]") @template = content end |
#template_url ⇒ Object
Deprecated
70 71 72 73 |
# File 'lib/fog/openstack/models/orchestration/stack.rb', line 70 def template_url Fog::Logger.deprecation("#template_url is deprecated, use it in options for #save(options) instead [light_black](#{caller.first})[/]") @template_url end |
#template_url=(url) ⇒ Object
Deprecated
76 77 78 79 |
# File 'lib/fog/openstack/models/orchestration/stack.rb', line 76 def template_url=(url) Fog::Logger.deprecation("#template_url= is deprecated, use it in options for #save(options) instead [light_black](#{caller.first})[/]") @template_url = url end |
#timeout_in_minutes ⇒ Object
Deprecated
88 89 90 91 |
# File 'lib/fog/openstack/models/orchestration/stack.rb', line 88 def timeout_in_minutes Fog::Logger.deprecation("#timeout_in_minutes is deprecated, set timeout_mins in options for save(options) instead [light_black](#{caller.first})[/]") timeout_mins end |
#timeout_in_minutes=(minutes) ⇒ Object
Deprecated
94 95 96 97 |
# File 'lib/fog/openstack/models/orchestration/stack.rb', line 94 def timeout_in_minutes=(minutes) Fog::Logger.deprecation("#timeout_in_minutes=(minutes) is deprecated, set timeout_mins in options for save(options) instead [light_black](#{caller.first})[/]") timeout_mins = minutes end |
#update ⇒ Object
Deprecated
32 33 34 35 36 |
# File 'lib/fog/openstack/models/orchestration/stack.rb', line 32 def update Fog::Logger.deprecation("#update is deprecated, use #save(options) instead [light_black](#{caller.first})[/]") requires :stack_name service.update_stack(self, ).body['stack'] end |