Sha256: 955d2846505c0cc812046c07d48958e7740600434afb0b13a8fe6f3b4cc5d972

Contents?: true

Size: 894 Bytes

Versions: 39

Compression:

Stored size: 894 Bytes

Contents

module Fog
  module Orchestration
    class OpenStack
      class Real

        # Delete a stack.
        #
        # @param stack_name [String] Name of the stack to delete.
        # @param stack_id [String] ID of the stack to delete.
        #
        # @return [Excon::Response]
        #
        # @see http://docs.amazonwebservices.com/AWSCloudFormation/latest/APIReference/API_DeleteStack.html

        def delete_stack(stack_name, stack_id)
          request(
            :expects  => 204,
            :path => "stacks/#{stack_name}/#{stack_id}",
            :method => 'DELETE'
          )
        end

      end

      class Mock
        def delete_stack(stack_name, stack_id)
          self.data[:stacks].delete(stack_id)

          response = Excon::Response.new
          response.status = 204
          response.body = {}
          response
        end
      end
    end
  end
end

Version data entries

39 entries across 39 versions & 2 rubygems

Version Path
fog-1.22.0 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-1.21.0 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-maestrodev-1.20.0.20140305101839 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-maestrodev-1.20.0.20140305101305 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-maestrodev-1.19.0.20140212012611 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-1.20.0 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-maestrodev-1.19.0.20140110004459 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-maestrodev-1.19.0.20140110003812 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-maestrodev-1.19.0.20140109202555 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-maestrodev-1.19.0.20140107192102 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-maestrodev-1.19.0.20140107142106 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-maestrodev-1.19.0.20131219203941 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-maestrodev-1.18.0.20131219193542 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-1.19.0 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-maestrodev-1.18.0.20131219033443 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-maestrodev-1.18.0.20131219032002 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-maestrodev-1.18.0.20131219030716 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-maestrodev-1.18.0.20131219022322 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-maestrodev-1.18.0.20131218202447 lib/fog/openstack/requests/orchestration/delete_stack.rb
fog-maestrodev-1.18.0.20131209091424 lib/fog/openstack/requests/orchestration/delete_stack.rb