Sha256: c70800490507197bfe845007b4355734024e4165a20a27999fe5a78ae67b4d24
Contents?: true
Size: 1.06 KB
Versions: 28
Compression:
Stored size: 1.06 KB
Contents
module Fog module Compute class Cloudstack class Real # Deletes security group # # {CloudStack API Reference}[http://cloudstack.apache.org/docs/api/apidocs-4.4/root_admin/deleteSecurityGroup.html] def delete_security_group(*args) options = {} if args[0].is_a? Hash options = args[0] options.merge!('command' => 'deleteSecurityGroup') else options.merge!('command' => 'deleteSecurityGroup') end request(options) end end class Mock def delete_security_group(options={}) security_group_id = options['id'] if self.data[:security_groups][security_group_id] self.data[:security_groups].delete(security_group_id) { "deletesecuritygroupresponse" => { "success" => "true" } } else raise Fog::Compute::Cloudstack::BadRequest.new('No security_group found') end end end end end end
Version data entries
28 entries across 26 versions & 4 rubygems