ECR / Client / put_registry_scanning_configuration
put_registry_scanning_configuration#
- ECR.Client.put_registry_scanning_configuration(**kwargs)#
Creates or updates the scanning configuration for your private registry.
See also: AWS API Documentation
Request Syntax
response = client.put_registry_scanning_configuration( scanType='BASIC'|'ENHANCED', rules=[ { 'scanFrequency': 'SCAN_ON_PUSH'|'CONTINUOUS_SCAN'|'MANUAL', 'repositoryFilters': [ { 'filter': 'string', 'filterType': 'WILDCARD' }, ] }, ] )
- Parameters:
scanType (string) –
The scanning type to set for the registry.
When a registry scanning configuration is not defined, by default the
BASIC
scan type is used. When basic scanning is used, you may specify filters to determine which individual repositories, or all repositories, are scanned when new images are pushed to those repositories. Alternatively, you can do manual scans of images with basic scanning.When the
ENHANCED
scan type is set, Amazon Inspector provides automated vulnerability scanning. You may choose between continuous scanning or scan on push and you may specify filters to determine which individual repositories, or all repositories, are scanned.rules (list) –
The scanning rules to use for the registry. A scanning rule is used to determine which repository filters are used and at what frequency scanning will occur.
(dict) –
The details of a scanning rule for a private registry.
scanFrequency (string) – [REQUIRED]
The frequency that scans are performed at for a private registry. When the
ENHANCED
scan type is specified, the supported scan frequencies areCONTINUOUS_SCAN
andSCAN_ON_PUSH
. When theBASIC
scan type is specified, theSCAN_ON_PUSH
andMANUAL
scan frequencies are supported.repositoryFilters (list) – [REQUIRED]
The repository filters associated with the scanning configuration for a private registry.
(dict) –
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.
filter (string) – [REQUIRED]
The filter to use when scanning.
filterType (string) – [REQUIRED]
The type associated with the filter.
- Return type:
dict
- Returns:
Response Syntax
{ 'registryScanningConfiguration': { 'scanType': 'BASIC'|'ENHANCED', 'rules': [ { 'scanFrequency': 'SCAN_ON_PUSH'|'CONTINUOUS_SCAN'|'MANUAL', 'repositoryFilters': [ { 'filter': 'string', 'filterType': 'WILDCARD' }, ] }, ] } }
Response Structure
(dict) –
registryScanningConfiguration (dict) –
The scanning configuration for your registry.
scanType (string) –
The type of scanning configured for the registry.
rules (list) –
The scanning rules associated with the registry.
(dict) –
The details of a scanning rule for a private registry.
scanFrequency (string) –
The frequency that scans are performed at for a private registry. When the
ENHANCED
scan type is specified, the supported scan frequencies areCONTINUOUS_SCAN
andSCAN_ON_PUSH
. When theBASIC
scan type is specified, theSCAN_ON_PUSH
andMANUAL
scan frequencies are supported.repositoryFilters (list) –
The repository filters associated with the scanning configuration for a private registry.
(dict) –
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.
filter (string) –
The filter to use when scanning.
filterType (string) –
The type associated with the filter.
Exceptions
ECR.Client.exceptions.ServerException
ECR.Client.exceptions.InvalidParameterException
ECR.Client.exceptions.ValidationException