Copyright | (c) 2013-2018 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
Network.AWS.AutoScaling.DetachInstances
Description
Removes one or more instances from the specified Auto Scaling group.
After the instances are detached, you can manage them independent of the Auto Scaling group.
If you do not specify the option to decrement the desired capacity, Auto Scaling launches instances to replace the ones that are detached.
If there is a Classic Load Balancer attached to the Auto Scaling group, the instances are deregistered from the load balancer. If there are target groups attached to the Auto Scaling group, the instances are deregistered from the target groups.
For more information, see Detach EC2 Instances from Your Auto Scaling Group in the Auto Scaling User Guide .
- detachInstances :: Text -> Bool -> DetachInstances
- data DetachInstances
- diInstanceIds :: Lens' DetachInstances [Text]
- diAutoScalingGroupName :: Lens' DetachInstances Text
- diShouldDecrementDesiredCapacity :: Lens' DetachInstances Bool
- detachInstancesResponse :: Int -> DetachInstancesResponse
- data DetachInstancesResponse
- dirsActivities :: Lens' DetachInstancesResponse [Activity]
- dirsResponseStatus :: Lens' DetachInstancesResponse Int
Creating a Request
Creates a value of DetachInstances
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
diInstanceIds
- The IDs of the instances. You can specify up to 20 instances.diAutoScalingGroupName
- The name of the Auto Scaling group.diShouldDecrementDesiredCapacity
- Indicates whether the Auto Scaling group decrements the desired capacity value by the number of instances detached.
data DetachInstances #
See: detachInstances
smart constructor.
Instances
Request Lenses
diInstanceIds :: Lens' DetachInstances [Text] #
The IDs of the instances. You can specify up to 20 instances.
diAutoScalingGroupName :: Lens' DetachInstances Text #
The name of the Auto Scaling group.
diShouldDecrementDesiredCapacity :: Lens' DetachInstances Bool #
Indicates whether the Auto Scaling group decrements the desired capacity value by the number of instances detached.
Destructuring the Response
Arguments
:: Int | |
-> DetachInstancesResponse |
Creates a value of DetachInstancesResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
dirsActivities
- The activities related to detaching the instances from the Auto Scaling group.dirsResponseStatus
- -- | The response status code.
data DetachInstancesResponse #
See: detachInstancesResponse
smart constructor.
Response Lenses
dirsActivities :: Lens' DetachInstancesResponse [Activity] #
The activities related to detaching the instances from the Auto Scaling group.
dirsResponseStatus :: Lens' DetachInstancesResponse Int #
- - | The response status code.