AWS autoscaling documentation change
Summary
Updated documentation to consistently use 'Amazon EC2 Auto Scaling group' terminology instead of 'Auto Scaling group' throughout the file. Added clarification about IAM role requirements for lifecycle hooks and updated section headers.
Security assessment
Changes primarily involve branding/naming consistency updates rather than security-related content. While there are references to IAM roles and policies (security elements), these were already present in previous documentation. The updates clarify existing security requirements rather than introducing new security features or addressing vulnerabilities.
Diff
diff --git a/autoscaling/ec2/userguide/prepare-for-lifecycle-notifications.md b/autoscaling/ec2/userguide/prepare-for-lifecycle-notifications.md index e5157507e..e1368686a 100644 --- a//autoscaling/ec2/userguide/prepare-for-lifecycle-notifications.md +++ b//autoscaling/ec2/userguide/prepare-for-lifecycle-notifications.md @@ -7 +7 @@ Configure a notification target -# Prepare to add a lifecycle hook to your Auto Scaling group +# Prepare to add a lifecycle hook to your Amazon EC2 Auto Scaling group @@ -9 +9 @@ Configure a notification target -Before you add a lifecycle hook to your Auto Scaling group, be sure that your user data script or notification target is set up correctly. +Before you add a lifecycle hook to your Amazon EC2 Auto Scaling group, be sure that your user data script or notification target is set up correctly. @@ -11 +11 @@ Before you add a lifecycle hook to your Auto Scaling group, be sure that your us - * To use a user data script to perform custom actions on your instances as they are launching, you do not need to configure a notification target. However, you must have already created the launch template or launch configuration that specifies your user data script and associated it with your Auto Scaling group. For more information about user data scripts, see [Run commands on your Linux instance at launch](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/user-data.html) in the _Amazon EC2 User Guide_. + * To use a user data script to perform custom actions on your instances as they are launching, you do not need to configure a notification target. However, you must have already created the launch template or launch configuration that specifies your user data script and associated it with your Amazon EC2 Auto Scaling group. For more information about user data scripts, see [Run commands on your Linux instance at launch](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/user-data.html) in the _Amazon EC2 User Guide_. @@ -13 +13 @@ Before you add a lifecycle hook to your Auto Scaling group, be sure that your us - * To signal Amazon EC2 Auto Scaling when the lifecycle action is complete, you must add the [CompleteLifecycleAction](https://docs.aws.amazon.com/autoscaling/ec2/APIReference/API_CompleteLifecycleAction.html) API call to the script, and you must manually create an IAM role with a policy that allows Auto Scaling instances to call this API. Your launch template or launch configuration must specify this role using an IAM instance profile that gets attached to your Amazon EC2 instances at launch. For more information, see [Complete a lifecycle action in an Auto Scaling group](./completing-lifecycle-hooks.html) and [IAM role for applications that run on Amazon EC2 instances](./us-iam-role.html). + * To signal Amazon EC2 Auto Scaling when the lifecycle action is complete, you must add the [CompleteLifecycleAction](https://docs.aws.amazon.com/autoscaling/ec2/APIReference/API_CompleteLifecycleAction.html) API call to the script, and you must manually create an IAM role with a policy that allows Amazon EC2 Auto Scaling instances to call this API. Your launch template or launch configuration must specify this role using an IAM instance profile that gets attached to your Amazon EC2 instances at launch. For more information, see [Complete a lifecycle action in an Amazon EC2 Auto Scaling group](./completing-lifecycle-hooks.html) and [IAM role for applications that run on Amazon EC2 instances](./us-iam-role.html). @@ -28 +28 @@ By default, when you add a lifecycle hook in the console, Amazon EC2 Auto Scalin -You can add lifecycle hooks to an Auto Scaling group to perform custom actions when an instance enters a wait state. You can choose a target service to perform these actions depending on your preferred development approach. +You can add lifecycle hooks to an Amazon EC2 Auto Scaling group to perform custom actions when an instance enters a wait state. You can choose a target service to perform these actions depending on your preferred development approach. @@ -66 +66 @@ The following procedures cover how to set up your notification target. -The EventBridge rule, Lambda function, Amazon SNS topic, and Amazon SQS queue that you use with lifecycle hooks must always be in the same Region where you created your Auto Scaling group. +The EventBridge rule, Lambda function, Amazon SNS topic, and Amazon SQS queue that you use with lifecycle hooks must always be in the same Region where you created your Amazon EC2 Auto Scaling group. @@ -90 +90 @@ For an introductory tutorial that is directed towards console users, see [Tutori -The following example shows the `pattern.json` for an instance launch lifecycle action. Replace the text in _`italics`_ with the name of your Auto Scaling group. +The following example shows the `pattern.json` for an instance launch lifecycle action. Replace the text in _`italics`_ with the name of your Amazon EC2 Auto Scaling group. @@ -102 +102 @@ If the command runs successfully, EventBridge responds with the ARN of the rule. -To create a rule that matches for other events, modify the event pattern. For more information, see [Use EventBridge to handle Auto Scaling events](./automating-ec2-auto-scaling-with-eventbridge.html). +To create a rule that matches for other events, modify the event pattern. For more information, see [Use EventBridge to handle Amazon EC2 Auto Scaling events](./automating-ec2-auto-scaling-with-eventbridge.html). @@ -139 +139 @@ The `Statement` value is a JSON string version of the statement that was added t - 5. After you have followed these instructions, continue on to [Add lifecycle hooks to your Auto Scaling group](./adding-lifecycle-hooks.html) as a next step. + 5. After you have followed these instructions, continue on to [Add lifecycle hooks to your Amazon EC2 Auto Scaling group](./adding-lifecycle-hooks.html) as a next step. @@ -150 +150 @@ You can use Amazon SNS to set up a notification target (an SNS topic) to receive - 1. Create an Amazon SNS topic by using either the [Amazon SNS console](https://console.aws.amazon.com/sns/) or the following [create-topic](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/sns/create-topic.html) command. Ensure that the topic is in the same Region as the Auto Scaling group that you're using. For more information, see [Getting started with Amazon SNS](https://docs.aws.amazon.com/sns/latest/dg/sns-getting-started.html) in the _Amazon Simple Notification Service Developer Guide_. + 1. Create an Amazon SNS topic by using either the [Amazon SNS console](https://console.aws.amazon.com/sns/) or the following [create-topic](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/sns/create-topic.html) command. Ensure that the topic is in the same Region as the Amazon EC2 Auto Scaling group that you're using. For more information, see [Getting started with Amazon SNS](https://docs.aws.amazon.com/sns/latest/dg/sns-getting-started.html) in the _Amazon Simple Notification Service Developer Guide_. @@ -191 +191 @@ FIFO queues are not compatible with lifecycle hooks. - 1. Create an Amazon SQS queue by using the [Amazon SQS console](https://console.aws.amazon.com/sqs/). Ensure that the queue is in the same Region as the Auto Scaling group that you're using. For more information, see [Getting started with Amazon SQS](https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/sqs-getting-started.html) in the _Amazon Simple Queue Service Developer Guide_. + 1. Create an Amazon SQS queue by using the [Amazon SQS console](https://console.aws.amazon.com/sqs/). Ensure that the queue is in the same Region as the Amazon EC2 Auto Scaling group that you're using. For more information, see [Getting started with Amazon SQS](https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/sqs-getting-started.html) in the _Amazon Simple Queue Service Developer Guide_. @@ -234 +234 @@ If you want to create a new Lambda function, see [Create the Lambda function](./ - 4. Scroll down to **Resource-based policy** and then choose **Add permissions**. A resource-based policy is used to grant permissions to invoke your function to the principal that is specified in the policy. In this case, the principal will be the [Amazon EC2 Auto Scaling service-linked role](https://docs.aws.amazon.com/autoscaling/ec2/userguide/autoscaling-service-linked-role.html) that is associated with the Auto Scaling group. + 4. Scroll down to **Resource-based policy** and then choose **Add permissions**. A resource-based policy is used to grant permissions to invoke your function to the principal that is specified in the policy. In this case, the principal will be the [Amazon EC2 Auto Scaling service-linked role](https://docs.aws.amazon.com/autoscaling/ec2/userguide/autoscaling-service-linked-role.html) that is associated with the Amazon EC2 Auto Scaling group. @@ -269 +269 @@ The message includes the following information: - * `AutoScalingGroupName` — The name of the Auto Scaling group. + * `AutoScalingGroupName` — The name of the Amazon EC2 Auto Scaling group. @@ -321 +321 @@ To use the Amazon Web Services Documentation, Javascript must be enabled. Please -How lifecycle hooks work in Auto Scaling groups +How lifecycle hooks work in Amazon EC2 Auto Scaling groups @@ -323 +323 @@ How lifecycle hooks work in Auto Scaling groups -Retrieve the target lifecycle state +Control instance retention with instance lifecycle policies