Defines the default patch baseline for the relevant operating system.
To reset the Amazon Web Services-predefined patch baseline as the default, specify the full patch baseline Amazon Resource Name (ARN) as the baseline ID value. For example, for CentOS, specify arn:aws:ssm:us-east-2:733109147000:patchbaseline/pb-0574b43a65ea646ed instead of pb-0574b43a65ea646ed.
Parameters:
-
baseline_id
(BaselineId)
–
The ID of the patch baseline that should be the default patch baseline.
Raises:
-
DoesNotExistException
–
Error returned when the ID specified for a resource, such as a maintenance window or patch baseline, doesn't exist.
For information about resource quotas in Amazon Web Services Systems Manager, see Systems Manager service quotas in the Amazon Web Services General Reference.
-
InternalServerError
–
An error occurred on the server side.
-
InvalidResourceId
–
The resource ID isn't valid. Verify that you entered the correct ID and try again.
-
UnknownServiceError
–
The service returned an error code this client does not model.
Source code in docs_src/capo_ssm/_services/async_ssm.py
| async def register_default_patch_baseline(
self,
baseline_id: "capo_ssm.types.baseline_id.BaselineId",
*,
config_overrides: Optional[AsyncSSMClientConfig] = None,
) -> "capo_ssm.types.register_default_patch_baseline_result.RegisterDefaultPatchBaselineResult":
"""<p>Defines the default patch baseline for the relevant operating system.</p> <p>To reset the Amazon Web Services-predefined patch baseline as the default, specify the full patch baseline Amazon Resource Name (ARN) as the baseline ID value. For example, for CentOS, specify <code>arn:aws:ssm:us-east-2:733109147000:patchbaseline/pb-0574b43a65ea646ed</code> instead of <code>pb-0574b43a65ea646ed</code>.</p>
Args:
baseline_id: <p>The ID of the patch baseline that should be the default patch baseline.</p>
Raises:
capo_ssm.errors.does_not_exist_exception.DoesNotExistException: <p>Error returned when the ID specified for a resource, such as a maintenance window or patch baseline, doesn't exist.</p> <p>For information about resource quotas in Amazon Web Services Systems Manager, see <a href="https://docs.aws.amazon.com/general/latest/gr/ssm.html#limits_ssm">Systems Manager service quotas</a> in the <i>Amazon Web Services General Reference</i>.</p>
capo_ssm.errors.internal_server_error.InternalServerError: <p>An error occurred on the server side.</p>
capo_ssm.errors.invalid_resource_id.InvalidResourceId: <p>The resource ID isn't valid. Verify that you entered the correct ID and try again.</p>
capo_ssm.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_ssm.types.register_default_patch_baseline_request.RegisterDefaultPatchBaselineRequest]",
) -> AsyncOperationResponse[
"capo_ssm.types.register_default_patch_baseline_result.RegisterDefaultPatchBaselineResult"
]:
import capo_ssm._operations.amazon_ssm.register_default_patch_baseline
(
output,
http_response,
) = await capo_ssm._operations.amazon_ssm.register_default_patch_baseline.async_register_default_patch_baseline(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("RegisterDefaultPatchBaseline")
)
input_: capo_ssm.types.register_default_patch_baseline_request.RegisterDefaultPatchBaselineRequest = {
"baseline_id": baseline_id
}
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|