Resource
dcloud_ecr_repository
A container image repository. Push to <org>.ecr.<domain>/<name> with docker, crane, oras or helm. Deleting a repository deletes its images; their layers are garbage-collected.
Example Usage
resource "dcloud_ecr_repository" "api" {
name = "team/api"
description = "The API service image"
# Release tags never move; `latest` still does.
tag_mutability = "immutable"
tag_mutability_exclusions = ["latest"]
}Schema
Required
name(String) Repository name: lowercase path components, e.g.apiorteam/api. Changing it replaces the resource.
Optional
description(String) Free text shown with the repository, up to 256 characters; none when omitted. Up to 256 characters.project(String) The project (its slug) the resource lives in. At create: this, else the provider'sproject, else Default. Changing it moves the resource and its parts; it is never replaced.storage_quota_bytes(Number) Cap in bytes on every layer this repository holds, shared ones included: 1 MiB (1048576) to 1 PiB. null: no repository cap (the organization quota still applies). A push over it is refused; lowering it deletes nothing. No cap when omitted.tag_mutability(String)immutablerefuses a push that would move an existing tag to a different image; re-pushing the same image is fine. Defaultmutable. One of:mutable,immutable.tag_mutability_exclusions(List of String) Tags (*globs) that stay mutable in an immutable repository, e.g.["latest"].tags(Map of String) Tags, key → value. Once set here, only these keys are managed; tags Deutsche Cloud adds itself are left alone.visibility(String) private: every pull needs a credential with ecr:PullImage. public: anyone can pull this repository’s images without credentials (read-only, and only the layers its own images reference). private when omitted One of:private,public.
Read-Only
id(String) The resource's id.
Import
Import is supported using the following syntax:
The terraform import command can be used, for example:
terraform import dcloud_ecr_repository.api <repository-id>Generated from the provider's schema.