CfnRegistryScanningConfigurationPropsMixin

class aws_cdk.mixins_preview.aws_ecr.mixins.CfnRegistryScanningConfigurationPropsMixin(props, *, strategy=None)

Bases: Mixin

The scanning configuration for a private registry.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ecr-registryscanningconfiguration.html

CloudformationResource:

AWS::ECR::RegistryScanningConfiguration

Mixin:

true

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview import mixins
from aws_cdk.mixins_preview.aws_ecr import mixins as ecr_mixins

cfn_registry_scanning_configuration_props_mixin = ecr_mixins.CfnRegistryScanningConfigurationPropsMixin(ecr_mixins.CfnRegistryScanningConfigurationMixinProps(
    rules=[ecr_mixins.CfnRegistryScanningConfigurationPropsMixin.ScanningRuleProperty(
        repository_filters=[ecr_mixins.CfnRegistryScanningConfigurationPropsMixin.RepositoryFilterProperty(
            filter="filter",
            filter_type="filterType"
        )],
        scan_frequency="scanFrequency"
    )],
    scan_type="scanType"
),
    strategy=mixins.PropertyMergeStrategy.OVERRIDE
)

Create a mixin to apply properties to AWS::ECR::RegistryScanningConfiguration.

Parameters:

Methods

apply_to(construct)

Apply the mixin properties to the construct.

Parameters:

construct (IConstruct)

Return type:

IConstruct

supports(construct)

Check if this mixin supports the given construct.

Parameters:

construct (IConstruct)

Return type:

bool

Attributes

CFN_PROPERTY_KEYS = ['rules', 'scanType']

Static Methods

classmethod is_mixin(x)

(experimental) Checks if x is a Mixin.

Parameters:

x (Any) – Any object.

Return type:

bool

Returns:

true if x is an object created from a class which extends Mixin.

Stability:

experimental

RepositoryFilterProperty

class CfnRegistryScanningConfigurationPropsMixin.RepositoryFilterProperty(*, filter=None, filter_type=None)

Bases: object

The filter settings used with image replication.

Specifying a repository filter to a replication rule provides a method for controlling which repositories in a private registry are replicated. If no filters are added, the contents of all repositories are replicated.

Parameters:
  • filter (Optional[str]) – The filter to use when scanning.

  • filter_type (Optional[str]) – The type associated with the filter.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ecr-registryscanningconfiguration-repositoryfilter.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_ecr import mixins as ecr_mixins

repository_filter_property = ecr_mixins.CfnRegistryScanningConfigurationPropsMixin.RepositoryFilterProperty(
    filter="filter",
    filter_type="filterType"
)

Attributes

filter

The filter to use when scanning.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ecr-registryscanningconfiguration-repositoryfilter.html#cfn-ecr-registryscanningconfiguration-repositoryfilter-filter

filter_type

The type associated with the filter.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ecr-registryscanningconfiguration-repositoryfilter.html#cfn-ecr-registryscanningconfiguration-repositoryfilter-filtertype

ScanningRuleProperty

class CfnRegistryScanningConfigurationPropsMixin.ScanningRuleProperty(*, repository_filters=None, scan_frequency=None)

Bases: object

The scanning rules associated with the registry.

Parameters:
  • repository_filters (Union[IResolvable, Sequence[Union[IResolvable, RepositoryFilterProperty, Dict[str, Any]]], None]) – The details of a scanning repository filter. For more information on how to use filters, see Using filters in the Amazon Elastic Container Registry User Guide .

  • scan_frequency (Optional[str]) – The frequency that scans are performed at for a private registry. When the ENHANCED scan type is specified, the supported scan frequencies are CONTINUOUS_SCAN and SCAN_ON_PUSH . When the BASIC scan type is specified, the SCAN_ON_PUSH scan frequency is supported. If scan on push is not specified, then the MANUAL scan frequency is set by default.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ecr-registryscanningconfiguration-scanningrule.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_ecr import mixins as ecr_mixins

scanning_rule_property = ecr_mixins.CfnRegistryScanningConfigurationPropsMixin.ScanningRuleProperty(
    repository_filters=[ecr_mixins.CfnRegistryScanningConfigurationPropsMixin.RepositoryFilterProperty(
        filter="filter",
        filter_type="filterType"
    )],
    scan_frequency="scanFrequency"
)

Attributes

repository_filters

The details of a scanning repository filter.

For more information on how to use filters, see Using filters in the Amazon Elastic Container Registry User Guide .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ecr-registryscanningconfiguration-scanningrule.html#cfn-ecr-registryscanningconfiguration-scanningrule-repositoryfilters

scan_frequency

The frequency that scans are performed at for a private registry.

When the ENHANCED scan type is specified, the supported scan frequencies are CONTINUOUS_SCAN and SCAN_ON_PUSH . When the BASIC scan type is specified, the SCAN_ON_PUSH scan frequency is supported. If scan on push is not specified, then the MANUAL scan frequency is set by default.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ecr-registryscanningconfiguration-scanningrule.html#cfn-ecr-registryscanningconfiguration-scanningrule-scanfrequency