Class: Fog::Rackspace::Orchestration::Stack
- Inherits:
-
Model
- Object
- Model
- Fog::Rackspace::Orchestration::Stack
- Defined in:
- lib/fog/rackspace/models/orchestration/stack.rb
Instance Method Summary collapse
- #abandon ⇒ Object
- #delete ⇒ Object
- #details ⇒ Object
- #events(options = {}) ⇒ Object
- #resources ⇒ Object
- #save(options = {}) ⇒ Object
- #template ⇒ Object
Instance Method Details
#abandon ⇒ Object
38 39 40 |
# File 'lib/fog/rackspace/models/orchestration/stack.rb', line 38 def abandon service.abandon_stack(self) end |
#delete ⇒ Object
42 43 44 |
# File 'lib/fog/rackspace/models/orchestration/stack.rb', line 42 def delete service.delete_stack(self) end |
#details ⇒ Object
12 13 14 15 16 |
# File 'lib/fog/rackspace/models/orchestration/stack.rb', line 12 def details service.show_stack_details(self.stack_name, self.id).body['stack'] rescue Fog::Rackspace::Orchestration::NotFound nil end |
#events(options = {}) ⇒ Object
22 23 24 |
# File 'lib/fog/rackspace/models/orchestration/stack.rb', line 22 def events(={}) @events ||= service.events.all(self, ) end |
#resources ⇒ Object
18 19 20 |
# File 'lib/fog/rackspace/models/orchestration/stack.rb', line 18 def resources @resources ||= service.resources.all(self) end |
#save(options = {}) ⇒ Object
30 31 32 33 34 35 36 |
# File 'lib/fog/rackspace/models/orchestration/stack.rb', line 30 def save(={}) if persisted? service.update_stack(self, ).body['stack'] else service.stacks.create() end end |
#template ⇒ Object
26 27 28 |
# File 'lib/fog/rackspace/models/orchestration/stack.rb', line 26 def template @template ||= service.templates.get(self) end |