From c7932321e0b68c131ccb4b23831839e7c03897e4 Mon Sep 17 00:00:00 2001 From: Jonas Furrer Date: Wed, 17 Nov 2021 13:16:49 +0100 Subject: [PATCH] Add information that PAT is needed --- README.md | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 2af3949..9f5bfc9 100644 --- a/README.md +++ b/README.md @@ -2,28 +2,28 @@ This action deletes old versions of containers on Github container registry (ghcr.io). By default only the latest version. -This action works only with containers, no other package formats. +This action works only for containers, no other package format. +Since the [Github Token has no access to the container REST API](https://github.community/t/github-token-has-no-access-to-new-container-rest-apis/170395), a [PAT](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token) with packages read- and write-permission is needed to access the packages. ## Inputs ### `access-token` -**Required** Access token with packages read- and write-permisson. +**Required** Access token (PAT) with packages read- and write-permisson. ### `package-name` **Required** Name of the package to work with - required: true ### `versions-to-keep` How many versions should be left untouched. Default is '1', only the latest. ## Example usage ### Keep only the latest version: - uses: d22/cleanup-ghcr-containers-action@v0.3.0 + uses: d22/cleanup-ghcr-containers-action@v0.3.3 with: - access-token: ${{ secrets.GITHUB_TOKEN }} + access-token: ${{ secrets.PERSONAL_ACCESS_TOKEN }} package-name: 'master-tool-dev' ### Keep the latest and the two following versions: - uses: d22/cleanup-ghcr-containers-action@v0.3.0 + uses: d22/cleanup-ghcr-containers-action@v0.3.3 with: - access-token: ${{ secrets.MY_PAT }} + access-token: ${{ secrets.PERSONAL_ACCESS_TOKEN }} package-name: 'master-tool-dev' versions-to-keep: 3 \ No newline at end of file