lib/aws-sdk-ecr/client.rb in aws-sdk-ecr-1.65.0 vs lib/aws-sdk-ecr/client.rb in aws-sdk-ecr-1.66.0
- old
+ new
@@ -530,11 +530,11 @@
# resp.image_ids[0].image_digest #=> String
# resp.image_ids[0].image_tag #=> String
# resp.failures #=> Array
# resp.failures[0].image_id.image_digest #=> String
# resp.failures[0].image_id.image_tag #=> String
- # resp.failures[0].failure_code #=> String, one of "InvalidImageDigest", "InvalidImageTag", "ImageTagDoesNotMatchDigest", "ImageNotFound", "MissingDigestAndTag", "ImageReferencedByManifestList", "KmsError"
+ # resp.failures[0].failure_code #=> String, one of "InvalidImageDigest", "InvalidImageTag", "ImageTagDoesNotMatchDigest", "ImageNotFound", "MissingDigestAndTag", "ImageReferencedByManifestList", "KmsError", "UpstreamAccessDenied", "UpstreamTooManyRequests", "UpstreamUnavailable"
# resp.failures[0].failure_reason #=> String
#
# @see http://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/BatchDeleteImage AWS API Documentation
#
# @overload batch_delete_image(params = {})
@@ -631,11 +631,11 @@
# resp.images[0].image_manifest #=> String
# resp.images[0].image_manifest_media_type #=> String
# resp.failures #=> Array
# resp.failures[0].image_id.image_digest #=> String
# resp.failures[0].image_id.image_tag #=> String
- # resp.failures[0].failure_code #=> String, one of "InvalidImageDigest", "InvalidImageTag", "ImageTagDoesNotMatchDigest", "ImageNotFound", "MissingDigestAndTag", "ImageReferencedByManifestList", "KmsError"
+ # resp.failures[0].failure_code #=> String, one of "InvalidImageDigest", "InvalidImageTag", "ImageTagDoesNotMatchDigest", "ImageNotFound", "MissingDigestAndTag", "ImageReferencedByManifestList", "KmsError", "UpstreamAccessDenied", "UpstreamTooManyRequests", "UpstreamUnavailable"
# resp.failures[0].failure_reason #=> String
#
# @see http://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/BatchGetImage AWS API Documentation
#
# @overload batch_get_image(params = {})
@@ -745,47 +745,80 @@
req = build_request(:complete_layer_upload, params)
req.send_request(options)
end
# Creates a pull through cache rule. A pull through cache rule provides
- # a way to cache images from an external public registry in your Amazon
- # ECR private registry.
+ # a way to cache images from an upstream registry source in your Amazon
+ # ECR private registry. For more information, see [Using pull through
+ # cache rules][1] in the *Amazon Elastic Container Registry User Guide*.
#
+ #
+ #
+ # [1]: https://docs.aws.amazon.com/AmazonECR/latest/userguide/pull-through-cache.html
+ #
# @option params [required, String] :ecr_repository_prefix
# The repository name prefix to use when caching images from the source
# registry.
#
# @option params [required, String] :upstream_registry_url
# The registry URL of the upstream public registry to use as the source
- # for the pull through cache rule.
+ # for the pull through cache rule. The following is the syntax to use
+ # for each supported upstream registry.
#
+ # * Amazon ECR Public (`ecr-public`) - `public.ecr.aws`
+ #
+ # * Docker Hub (`docker-hub`) - `registry-1.docker.io`
+ #
+ # * Quay (`quay`) - `quay.io`
+ #
+ # * Kubernetes (`k8s`) - `registry.k8s.io`
+ #
+ # * GitHub Container Registry (`github-container-registry`) - `ghcr.io`
+ #
+ # * Microsoft Azure Container Registry (`azure-container-registry`) -
+ # `<custom>.azurecr.io`
+ #
# @option params [String] :registry_id
# The Amazon Web Services account ID associated with the registry to
# create the pull through cache rule for. If you do not specify a
# registry, the default registry is assumed.
#
+ # @option params [String] :upstream_registry
+ # The name of the upstream registry.
+ #
+ # @option params [String] :credential_arn
+ # The Amazon Resource Name (ARN) of the Amazon Web Services Secrets
+ # Manager secret that identifies the credentials to authenticate to the
+ # upstream registry.
+ #
# @return [Types::CreatePullThroughCacheRuleResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
#
# * {Types::CreatePullThroughCacheRuleResponse#ecr_repository_prefix #ecr_repository_prefix} => String
# * {Types::CreatePullThroughCacheRuleResponse#upstream_registry_url #upstream_registry_url} => String
# * {Types::CreatePullThroughCacheRuleResponse#created_at #created_at} => Time
# * {Types::CreatePullThroughCacheRuleResponse#registry_id #registry_id} => String
+ # * {Types::CreatePullThroughCacheRuleResponse#upstream_registry #upstream_registry} => String
+ # * {Types::CreatePullThroughCacheRuleResponse#credential_arn #credential_arn} => String
#
# @example Request syntax with placeholder values
#
# resp = client.create_pull_through_cache_rule({
# ecr_repository_prefix: "PullThroughCacheRuleRepositoryPrefix", # required
# upstream_registry_url: "Url", # required
# registry_id: "RegistryId",
+ # upstream_registry: "ecr-public", # accepts ecr-public, quay, k8s, docker-hub, github-container-registry, azure-container-registry
+ # credential_arn: "CredentialArn",
# })
#
# @example Response structure
#
# resp.ecr_repository_prefix #=> String
# resp.upstream_registry_url #=> String
# resp.created_at #=> Time
# resp.registry_id #=> String
+ # resp.upstream_registry #=> String, one of "ecr-public", "quay", "k8s", "docker-hub", "github-container-registry", "azure-container-registry"
+ # resp.credential_arn #=> String
#
# @see http://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/CreatePullThroughCacheRule AWS API Documentation
#
# @overload create_pull_through_cache_rule(params = {})
# @param [Hash] params ({})
@@ -959,10 +992,11 @@
#
# * {Types::DeletePullThroughCacheRuleResponse#ecr_repository_prefix #ecr_repository_prefix} => String
# * {Types::DeletePullThroughCacheRuleResponse#upstream_registry_url #upstream_registry_url} => String
# * {Types::DeletePullThroughCacheRuleResponse#created_at #created_at} => Time
# * {Types::DeletePullThroughCacheRuleResponse#registry_id #registry_id} => String
+ # * {Types::DeletePullThroughCacheRuleResponse#credential_arn #credential_arn} => String
#
# @example Request syntax with placeholder values
#
# resp = client.delete_pull_through_cache_rule({
# ecr_repository_prefix: "PullThroughCacheRuleRepositoryPrefix", # required
@@ -973,10 +1007,11 @@
#
# resp.ecr_repository_prefix #=> String
# resp.upstream_registry_url #=> String
# resp.created_at #=> Time
# resp.registry_id #=> String
+ # resp.credential_arn #=> String
#
# @see http://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/DeletePullThroughCacheRule AWS API Documentation
#
# @overload delete_pull_through_cache_rule(params = {})
# @param [Hash] params ({})
@@ -1004,24 +1039,27 @@
def delete_registry_policy(params = {}, options = {})
req = build_request(:delete_registry_policy, params)
req.send_request(options)
end
- # Deletes a repository. If the repository contains images, you must
- # either delete all images in the repository or use the `force` option
- # to delete the repository.
+ # Deletes a repository. If the repository isn't empty, you must either
+ # delete the contents of the repository or use the `force` option to
+ # delete the repository and have Amazon ECR delete all of its contents
+ # on your behalf.
#
# @option params [String] :registry_id
# The Amazon Web Services account ID associated with the registry that
# contains the repository to delete. If you do not specify a registry,
# the default registry is assumed.
#
# @option params [required, String] :repository_name
# The name of the repository to delete.
#
# @option params [Boolean] :force
- # If a repository contains images, forces the deletion.
+ # If true, deleting the repository force deletes the contents of the
+ # repository. If false, the repository must be empty before attempting
+ # to delete it.
#
# @return [Types::DeleteRepositoryResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
#
# * {Types::DeleteRepositoryResponse#repository #repository} => Types::Repository
#
@@ -1484,10 +1522,13 @@
# resp.pull_through_cache_rules #=> Array
# resp.pull_through_cache_rules[0].ecr_repository_prefix #=> String
# resp.pull_through_cache_rules[0].upstream_registry_url #=> String
# resp.pull_through_cache_rules[0].created_at #=> Time
# resp.pull_through_cache_rules[0].registry_id #=> String
+ # resp.pull_through_cache_rules[0].credential_arn #=> String
+ # resp.pull_through_cache_rules[0].upstream_registry #=> String, one of "ecr-public", "quay", "k8s", "docker-hub", "github-container-registry", "azure-container-registry"
+ # resp.pull_through_cache_rules[0].updated_at #=> Time
# resp.next_token #=> String
#
# @see http://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/DescribePullThroughCacheRules AWS API Documentation
#
# @overload describe_pull_through_cache_rules(params = {})
@@ -2790,10 +2831,57 @@
def untag_resource(params = {}, options = {})
req = build_request(:untag_resource, params)
req.send_request(options)
end
+ # Updates an existing pull through cache rule.
+ #
+ # @option params [String] :registry_id
+ # The Amazon Web Services account ID associated with the registry
+ # associated with the pull through cache rule. If you do not specify a
+ # registry, the default registry is assumed.
+ #
+ # @option params [required, String] :ecr_repository_prefix
+ # The repository name prefix to use when caching images from the source
+ # registry.
+ #
+ # @option params [required, String] :credential_arn
+ # The Amazon Resource Name (ARN) of the Amazon Web Services Secrets
+ # Manager secret that identifies the credentials to authenticate to the
+ # upstream registry.
+ #
+ # @return [Types::UpdatePullThroughCacheRuleResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
+ #
+ # * {Types::UpdatePullThroughCacheRuleResponse#ecr_repository_prefix #ecr_repository_prefix} => String
+ # * {Types::UpdatePullThroughCacheRuleResponse#registry_id #registry_id} => String
+ # * {Types::UpdatePullThroughCacheRuleResponse#updated_at #updated_at} => Time
+ # * {Types::UpdatePullThroughCacheRuleResponse#credential_arn #credential_arn} => String
+ #
+ # @example Request syntax with placeholder values
+ #
+ # resp = client.update_pull_through_cache_rule({
+ # registry_id: "RegistryId",
+ # ecr_repository_prefix: "PullThroughCacheRuleRepositoryPrefix", # required
+ # credential_arn: "CredentialArn", # required
+ # })
+ #
+ # @example Response structure
+ #
+ # resp.ecr_repository_prefix #=> String
+ # resp.registry_id #=> String
+ # resp.updated_at #=> Time
+ # resp.credential_arn #=> String
+ #
+ # @see http://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/UpdatePullThroughCacheRule AWS API Documentation
+ #
+ # @overload update_pull_through_cache_rule(params = {})
+ # @param [Hash] params ({})
+ def update_pull_through_cache_rule(params = {}, options = {})
+ req = build_request(:update_pull_through_cache_rule, params)
+ req.send_request(options)
+ end
+
# Uploads an image layer part to Amazon ECR.
#
# When an image is pushed, each new image layer is uploaded in parts.
# The maximum size of each image layer part can be 20971520 bytes (or
# about 20MB). The UploadLayerPart API is called once per each new image
@@ -2860,10 +2948,58 @@
def upload_layer_part(params = {}, options = {})
req = build_request(:upload_layer_part, params)
req.send_request(options)
end
+ # Validates an existing pull through cache rule for an upstream registry
+ # that requires authentication. This will retrieve the contents of the
+ # Amazon Web Services Secrets Manager secret, verify the syntax, and
+ # then validate that authentication to the upstream registry is
+ # successful.
+ #
+ # @option params [required, String] :ecr_repository_prefix
+ # The repository name prefix associated with the pull through cache
+ # rule.
+ #
+ # @option params [String] :registry_id
+ # The registry ID associated with the pull through cache rule. If you do
+ # not specify a registry, the default registry is assumed.
+ #
+ # @return [Types::ValidatePullThroughCacheRuleResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
+ #
+ # * {Types::ValidatePullThroughCacheRuleResponse#ecr_repository_prefix #ecr_repository_prefix} => String
+ # * {Types::ValidatePullThroughCacheRuleResponse#registry_id #registry_id} => String
+ # * {Types::ValidatePullThroughCacheRuleResponse#upstream_registry_url #upstream_registry_url} => String
+ # * {Types::ValidatePullThroughCacheRuleResponse#credential_arn #credential_arn} => String
+ # * {Types::ValidatePullThroughCacheRuleResponse#is_valid #is_valid} => Boolean
+ # * {Types::ValidatePullThroughCacheRuleResponse#failure #failure} => String
+ #
+ # @example Request syntax with placeholder values
+ #
+ # resp = client.validate_pull_through_cache_rule({
+ # ecr_repository_prefix: "PullThroughCacheRuleRepositoryPrefix", # required
+ # registry_id: "RegistryId",
+ # })
+ #
+ # @example Response structure
+ #
+ # resp.ecr_repository_prefix #=> String
+ # resp.registry_id #=> String
+ # resp.upstream_registry_url #=> String
+ # resp.credential_arn #=> String
+ # resp.is_valid #=> Boolean
+ # resp.failure #=> String
+ #
+ # @see http://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/ValidatePullThroughCacheRule AWS API Documentation
+ #
+ # @overload validate_pull_through_cache_rule(params = {})
+ # @param [Hash] params ({})
+ def validate_pull_through_cache_rule(params = {}, options = {})
+ req = build_request(:validate_pull_through_cache_rule, params)
+ req.send_request(options)
+ end
+
# @!endgroup
# @param params ({})
# @api private
def build_request(operation_name, params = {})
@@ -2873,10 +3009,10 @@
operation: config.api.operation(operation_name),
client: self,
params: params,
config: config)
context[:gem_name] = 'aws-sdk-ecr'
- context[:gem_version] = '1.65.0'
+ context[:gem_version] = '1.66.0'
Seahorse::Client::Request.new(handlers, context)
end
# Polls an API operation until a resource enters a desired state.
#