Skip to main content

default_patch_baselines

Creates, updates, deletes, gets or lists a default_patch_baselines resource.

Overview

Namedefault_patch_baselines
TypeResource
Idaws.ssm.default_patch_baselines

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
baseline_idstringThe ID of the default patch baseline. (pattern: <code>^[a-zA-Z0-9_-:/]{20,128}$</code>)
operating_systemstringThe operating system for the returned patch baseline. (WINDOWS, AMAZON_LINUX, AMAZON_LINUX_2, AMAZON_LINUX_2022, UBUNTU, REDHAT_ENTERPRISE_LINUX, SUSE, CENTOS, ORACLE_LINUX, DEBIAN, MACOS, RASPBIAN, ROCKY_LINUX, ALMA_LINUX, AMAZON_LINUX_2023)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_default_patch_baselineselectregionRetrieves the default patch baseline. Amazon Web Services Systems Manager supports creating multiple default patch baselines. For example, you can create a default patch baseline for each operating system. If you don't specify an operating system value, the default patch baseline for Windows is returned.
register_default_patch_baselineinsertregion, BaselineIdDefines 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

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples

Retrieves the default patch baseline. Amazon Web Services Systems Manager supports creating multiple default patch baselines. For example, you can create a default patch baseline for each operating system. If you don't specify an operating system value, the default patch baseline for Windows is returned.

SELECT
baseline_id,
operating_system
FROM aws.ssm.default_patch_baselines
WHERE region = '{{ region }}' -- required
;

INSERT examples

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.

INSERT INTO aws.ssm.default_patch_baselines (
BaselineId,
region
)
SELECT
'{{ BaselineId }}' /* required */,
'{{ region }}'
RETURNING
baseline_id
;