amazonka-ec2-1.3.5: Amazon Elastic Compute Cloud SDK.

Copyright(c) 2013-2015 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone
LanguageHaskell2010

Network.AWS.EC2.DeleteSecurityGroup

Contents

Description

Deletes a security group.

If you attempt to delete a security group that is associated with an instance, or is referenced by another security group, the operation fails with InUse in EC2-Classic or DependencyViolation in EC2-VPC.

See: AWS API Reference for DeleteSecurityGroup.

Synopsis

Creating a Request

deleteSecurityGroup :: DeleteSecurityGroup Source

Creates a value of DeleteSecurityGroup with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

Request Lenses

dsgGroupId :: Lens' DeleteSecurityGroup (Maybe Text) Source

The ID of the security group. Required for a nondefault VPC.

dsgGroupName :: Lens' DeleteSecurityGroup (Maybe Text) Source

EC2-Classic, default VPC
The name of the security group. You can specify either the security group name or the security group ID.

dsgDryRun :: Lens' DeleteSecurityGroup (Maybe Bool) Source

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Destructuring the Response

deleteSecurityGroupResponse :: DeleteSecurityGroupResponse Source

Creates a value of DeleteSecurityGroupResponse with the minimum fields required to make a request.