Copyright | (c) 2013-2021 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 |
Registers a target with a maintenance window.
Synopsis
- data RegisterTargetWithMaintenanceWindow = RegisterTargetWithMaintenanceWindow' {}
- newRegisterTargetWithMaintenanceWindow :: Text -> MaintenanceWindowResourceType -> RegisterTargetWithMaintenanceWindow
- registerTargetWithMaintenanceWindow_clientToken :: Lens' RegisterTargetWithMaintenanceWindow (Maybe Text)
- registerTargetWithMaintenanceWindow_ownerInformation :: Lens' RegisterTargetWithMaintenanceWindow (Maybe Text)
- registerTargetWithMaintenanceWindow_name :: Lens' RegisterTargetWithMaintenanceWindow (Maybe Text)
- registerTargetWithMaintenanceWindow_description :: Lens' RegisterTargetWithMaintenanceWindow (Maybe Text)
- registerTargetWithMaintenanceWindow_windowId :: Lens' RegisterTargetWithMaintenanceWindow Text
- registerTargetWithMaintenanceWindow_resourceType :: Lens' RegisterTargetWithMaintenanceWindow MaintenanceWindowResourceType
- registerTargetWithMaintenanceWindow_targets :: Lens' RegisterTargetWithMaintenanceWindow [Target]
- data RegisterTargetWithMaintenanceWindowResponse = RegisterTargetWithMaintenanceWindowResponse' {
- windowTargetId :: Maybe Text
- httpStatus :: Int
- newRegisterTargetWithMaintenanceWindowResponse :: Int -> RegisterTargetWithMaintenanceWindowResponse
- registerTargetWithMaintenanceWindowResponse_windowTargetId :: Lens' RegisterTargetWithMaintenanceWindowResponse (Maybe Text)
- registerTargetWithMaintenanceWindowResponse_httpStatus :: Lens' RegisterTargetWithMaintenanceWindowResponse Int
Creating a Request
data RegisterTargetWithMaintenanceWindow Source #
See: newRegisterTargetWithMaintenanceWindow
smart constructor.
RegisterTargetWithMaintenanceWindow' | |
|
Instances
newRegisterTargetWithMaintenanceWindow Source #
Create a value of RegisterTargetWithMaintenanceWindow
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:clientToken:RegisterTargetWithMaintenanceWindow'
, registerTargetWithMaintenanceWindow_clientToken
- User-provided idempotency token.
$sel:ownerInformation:RegisterTargetWithMaintenanceWindow'
, registerTargetWithMaintenanceWindow_ownerInformation
- User-provided value that will be included in any Amazon CloudWatch
Events events raised while running tasks for these targets in this
maintenance window.
$sel:name:RegisterTargetWithMaintenanceWindow'
, registerTargetWithMaintenanceWindow_name
- An optional name for the target.
$sel:description:RegisterTargetWithMaintenanceWindow'
, registerTargetWithMaintenanceWindow_description
- An optional description for the target.
$sel:windowId:RegisterTargetWithMaintenanceWindow'
, registerTargetWithMaintenanceWindow_windowId
- The ID of the maintenance window the target should be registered with.
$sel:resourceType:RegisterTargetWithMaintenanceWindow'
, registerTargetWithMaintenanceWindow_resourceType
- The type of target being registered with the maintenance window.
$sel:targets:RegisterTargetWithMaintenanceWindow'
, registerTargetWithMaintenanceWindow_targets
- The targets to register with the maintenance window. In other words, the
instances to run commands on when the maintenance window runs.
If a single maintenance window task is registered with multiple targets, its task invocations occur sequentially and not in parallel. If your task must run on multiple targets at the same time, register a task for each target individually and assign each task the same priority level.
You can specify targets using instance IDs, resource group names, or tags that have been applied to instances.
Example 1: Specify instance IDs
Key=InstanceIds,Values=instance-id-1,instance-id-2,instance-id-3
Example 2: Use tag key-pairs applied to instances
Key=tag:my-tag-key,Values=my-tag-value-1,my-tag-value-2
Example 3: Use tag-keys applied to instances
Key=tag-key,Values=my-tag-key-1,my-tag-key-2
Example 4: Use resource group names
Key=resource-groups:Name,Values=resource-group-name
Example 5: Use filters for resource group types
Key=resource-groups:ResourceTypeFilters,Values=resource-type-1,resource-type-2
For Key=resource-groups:ResourceTypeFilters
, specify resource types in
the following format
Key=resource-groups:ResourceTypeFilters,Values=AWS::EC2::INSTANCE,AWS::EC2::VPC
For more information about these examples formats, including the best use case for each one, see Examples: Register targets with a maintenance window in the Amazon Web Services Systems Manager User Guide.
Request Lenses
registerTargetWithMaintenanceWindow_clientToken :: Lens' RegisterTargetWithMaintenanceWindow (Maybe Text) Source #
User-provided idempotency token.
registerTargetWithMaintenanceWindow_ownerInformation :: Lens' RegisterTargetWithMaintenanceWindow (Maybe Text) Source #
User-provided value that will be included in any Amazon CloudWatch Events events raised while running tasks for these targets in this maintenance window.
registerTargetWithMaintenanceWindow_name :: Lens' RegisterTargetWithMaintenanceWindow (Maybe Text) Source #
An optional name for the target.
registerTargetWithMaintenanceWindow_description :: Lens' RegisterTargetWithMaintenanceWindow (Maybe Text) Source #
An optional description for the target.
registerTargetWithMaintenanceWindow_windowId :: Lens' RegisterTargetWithMaintenanceWindow Text Source #
The ID of the maintenance window the target should be registered with.
registerTargetWithMaintenanceWindow_resourceType :: Lens' RegisterTargetWithMaintenanceWindow MaintenanceWindowResourceType Source #
The type of target being registered with the maintenance window.
registerTargetWithMaintenanceWindow_targets :: Lens' RegisterTargetWithMaintenanceWindow [Target] Source #
The targets to register with the maintenance window. In other words, the instances to run commands on when the maintenance window runs.
If a single maintenance window task is registered with multiple targets, its task invocations occur sequentially and not in parallel. If your task must run on multiple targets at the same time, register a task for each target individually and assign each task the same priority level.
You can specify targets using instance IDs, resource group names, or tags that have been applied to instances.
Example 1: Specify instance IDs
Key=InstanceIds,Values=instance-id-1,instance-id-2,instance-id-3
Example 2: Use tag key-pairs applied to instances
Key=tag:my-tag-key,Values=my-tag-value-1,my-tag-value-2
Example 3: Use tag-keys applied to instances
Key=tag-key,Values=my-tag-key-1,my-tag-key-2
Example 4: Use resource group names
Key=resource-groups:Name,Values=resource-group-name
Example 5: Use filters for resource group types
Key=resource-groups:ResourceTypeFilters,Values=resource-type-1,resource-type-2
For Key=resource-groups:ResourceTypeFilters
, specify resource types in
the following format
Key=resource-groups:ResourceTypeFilters,Values=AWS::EC2::INSTANCE,AWS::EC2::VPC
For more information about these examples formats, including the best use case for each one, see Examples: Register targets with a maintenance window in the Amazon Web Services Systems Manager User Guide.
Destructuring the Response
data RegisterTargetWithMaintenanceWindowResponse Source #
See: newRegisterTargetWithMaintenanceWindowResponse
smart constructor.
RegisterTargetWithMaintenanceWindowResponse' | |
|
Instances
newRegisterTargetWithMaintenanceWindowResponse Source #
:: Int |
|
-> RegisterTargetWithMaintenanceWindowResponse |
Create a value of RegisterTargetWithMaintenanceWindowResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:windowTargetId:RegisterTargetWithMaintenanceWindowResponse'
, registerTargetWithMaintenanceWindowResponse_windowTargetId
- The ID of the target definition in this maintenance window.
$sel:httpStatus:RegisterTargetWithMaintenanceWindowResponse'
, registerTargetWithMaintenanceWindowResponse_httpStatus
- The response's http status code.
Response Lenses
registerTargetWithMaintenanceWindowResponse_windowTargetId :: Lens' RegisterTargetWithMaintenanceWindowResponse (Maybe Text) Source #
The ID of the target definition in this maintenance window.
registerTargetWithMaintenanceWindowResponse_httpStatus :: Lens' RegisterTargetWithMaintenanceWindowResponse Int Source #
The response's http status code.