Skip to content

Conversation

@dvan-sqsp
Copy link

Hi!

We have a use-case where we want to force our ECR repos to have tag mutability set to IMMUTABLE. Since we have repo's with create_repository set to true, we only want to modify ones that are managed by the drone plugin.

AWS ECR tag mutability is a string of MUTABLE or IMMUTABLE. To simplify usage, I decided to go with a boolean to avoid typos on the plugin usage side. By default, tag_immutable is false, thus keeping existing behavior. Depending on the boolean, the code will use the provided SDK constants for MUTABLE and IMMUTABLE

usage example:

steps:
  - name: push-image
    image: plugins/ecr
    settings:
      ...
      create_repository: true
      tag_immutable: true

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant