Sha256: 888175a83416fd43de28894119ccf1155ce3b9cb071dae57c55219db3ca9116d
Contents?: true
Size: 882 Bytes
Versions: 21
Compression:
Stored size: 882 Bytes
Contents
require 'fog/openstack/models/model' module Fog module OpenStack class Network class SecurityGroupRule < Fog::OpenStack::Model identity :id attribute :security_group_id attribute :direction attribute :protocol attribute :port_range_min attribute :port_range_max attribute :remote_ip_prefix attribute :ethertype attribute :remote_group_id attribute :tenant_id def destroy requires :id service.delete_security_group_rule(id) true end def save raise Fog::Errors::Error, 'Resaving an existing object may create a duplicate' if persisted? merge_attributes(service.create_security_group_rule(security_group_id, direction, attributes).body['security_group_rule']) true end end end end end
Version data entries
21 entries across 21 versions & 3 rubygems