ripplr-io / docr-image-remove

Remove old images from DigitalOcean's Container Registry
MIT License
15 stars 5 forks source link

Image Repository Example #2

Closed fulviocanducci closed 1 year ago

fulviocanducci commented 2 years ago

The image-repository configuration was not very clear, for example you have to put in the full name example: registry.digitalocean.com/ex/ab:v1 or ex/ab:v1, could you please exemplify?

Other Example:

- name: Remove old images from Container Registry
      uses: ripplr-io/docr-image-remove@v1
      with:
        image_repository: ex/ab:v1
        buffer_size: 10

or

- name: Remove old images from Container Registry
      uses: ripplr-io/docr-image-remove@v1
      with:
        image_repository: registry.digitalocean.com/ex/ab:v1
        buffer_size: 10

Could you clarify me about this configuration what should I pass as a value?

JeffreySoriano5 commented 1 year ago

Did you find what was the correct way?

fulviocanducci commented 1 year ago

ripplr-io/docr-image-remove

Yes!

The configuration requires the short name to work, example:

- name: Remove Old Images From Container Registry
  uses: ripplr-io/docr-image-remove@v1
  with:
    image_repository: "Short_Name"
    buffer_size: 1   

You just need to be logged in to Digital Ocean via doctl:

- name: Install doctl
  uses: digitalocean/action-doctl@v2
  with:
    token: ${{ secrets.DIGITALOCEAN_ACCESS }}

- name: Log in to DigitalOcean Container Registry with Short-lived Credentials
  run: doctl registry login

this was performed by github actions

JeffreySoriano5 commented 1 year ago

Thanks. Just found out by trial and error on a console.