dcloud ecr lifecycle-policy preview

Which images a policy would expire now

IAM ecr:GetLifecyclePolicyRead

The stored policy, or {"policy": …} to try one before saving it. Changes nothing. Answers per rule what it would expire (count, bytes) and per image the decision and why (a protection such as in-use, a keep clause, or the rule).

Synopsis

dcloud ecr lifecycle-policy preview id [flags]

Arguments

  • <id>Required

    string

    Also accepted as --id. Constraints: uuid

Flags

  • --policyOptional

    object

    A policy to try before saving it (AWS ECR JSON or ews-lifecycle/v1), previewed as if saved and active. Omitted: the policy that applies to the repository now

    Constraints: JSON

Example

dcloud ecr lifecycle-policy preview id

Generated from the API description, the same one the API checks requests against and the CLI is built from.