From b5b4224220f3d9f1182eba31406baadcfa39a184 Mon Sep 17 00:00:00 2001 From: peaklabs-dev <122374094+peaklabs-dev@users.noreply.github.com> Date: Mon, 9 Nov 2026 19:45:15 +0100 Subject: [PATCH 1/2] ci: bump GitHub Actions to the latest releases --- .github/workflows/actions.lock | 14 +++++++------- .github/workflows/main.yaml | 2 +- .github/workflows/nightly.yaml | 4 ++-- .github/workflows/pull-request.yaml | 2 +- .github/workflows/release.yaml | 8 ++++---- 5 files changed, 15 insertions(+), 15 deletions(-) diff --git a/.github/workflows/actions.lock b/.github/workflows/actions.lock index 9e841ce20f..3fe234676e 100644 --- a/.github/workflows/actions.lock +++ b/.github/workflows/actions.lock @@ -16,23 +16,23 @@ workflows: '.github/workflows/main.yaml': - 'actions/checkout@v7.0.1' - 'actions/download-artifact@v8.0.2' - - 'docker/login-action@v4.7.0' + - 'docker/login-action@v4.8.0' '.github/workflows/merge-forward.yaml': - 'actions/checkout@v7.0.1' '.github/workflows/nightly.yaml': - 'actions/checkout@v7.0.1' - 'actions/download-artifact@v8.0.2' - - 'docker/login-action@v4.7.0' + - 'docker/login-action@v4.8.0' '.github/workflows/pr-quality.yaml': - 'peakoss/anti-slop@v0.3.0' '.github/workflows/pull-request.yaml': - 'actions/checkout@v7.0.1' - 'actions/download-artifact@v8.0.2' - - 'docker/login-action@v4.7.0' + - 'docker/login-action@v4.8.0' '.github/workflows/release.yaml': - 'actions/checkout@v7.0.1' - 'actions/download-artifact@v8.0.2' - - 'docker/login-action@v4.7.0' + - 'docker/login-action@v4.8.0' '.github/workflows/request-docs-update.yaml': [] '.github/workflows/stale.yaml': - 'actions/stale@v11.0.0' @@ -70,9 +70,9 @@ dependencies: commit: 'sha1-c3c9e263c25d99ce0380d002d59b67737d91b0dc' owner_id: 5429470 repo_id: 241092383 - 'docker/login-action@v4.7.0': - ref: 'v4.7.0' - commit: 'sha1-81c6f93d4bc991e510b342a00b419b3bb4efc5c6' + 'docker/login-action@v4.8.0': + ref: 'v4.8.0' + commit: 'sha1-8aa5831fb8d48d8f76594c7ddde61ae58019f550' owner_id: 5429470 repo_id: 287743349 'docker/setup-buildx-action@v4.4.1': diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index 765dbd049b..a6c9d1ccc3 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -73,7 +73,7 @@ jobs: path: ${{ runner.temp }}/images - name: Log in to ghcr.io - uses: docker/login-action@v4.7.0 + uses: docker/login-action@v4.8.0 with: registry: ghcr.io username: ${{ github.actor }} diff --git a/.github/workflows/nightly.yaml b/.github/workflows/nightly.yaml index 8cb77a1971..63f8427b58 100644 --- a/.github/workflows/nightly.yaml +++ b/.github/workflows/nightly.yaml @@ -79,14 +79,14 @@ jobs: path: ${{ runner.temp }}/images - name: Log in to ghcr.io - uses: docker/login-action@v4.7.0 + uses: docker/login-action@v4.8.0 with: registry: ghcr.io username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} - name: Log in to docker.io - uses: docker/login-action@v4.7.0 + uses: docker/login-action@v4.8.0 with: username: ${{ secrets.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_TOKEN }} diff --git a/.github/workflows/pull-request.yaml b/.github/workflows/pull-request.yaml index 1755e7d97c..92f9bbe24d 100644 --- a/.github/workflows/pull-request.yaml +++ b/.github/workflows/pull-request.yaml @@ -67,7 +67,7 @@ jobs: path: ${{ runner.temp }}/images - name: Log in to ghcr.io - uses: docker/login-action@v4.7.0 + uses: docker/login-action@v4.8.0 with: registry: ghcr.io username: ${{ github.actor }} diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 5cf75ab7f8..1190f708a8 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -85,14 +85,14 @@ jobs: path: ${{ runner.temp }}/images - name: Log in to ghcr.io - uses: docker/login-action@v4.7.0 + uses: docker/login-action@v4.8.0 with: registry: ghcr.io username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} - name: Log in to docker.io - uses: docker/login-action@v4.7.0 + uses: docker/login-action@v4.8.0 with: username: ${{ secrets.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_TOKEN }} @@ -151,14 +151,14 @@ jobs: echo "tags=$tags" | tee -a "$GITHUB_OUTPUT" - name: Log in to ghcr.io - uses: docker/login-action@v4.7.0 + uses: docker/login-action@v4.8.0 with: registry: ghcr.io username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} - name: Log in to docker.io - uses: docker/login-action@v4.7.0 + uses: docker/login-action@v4.8.0 with: username: ${{ secrets.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_TOKEN }} From 152aff5389a39925adbfa642df1698f288c0368b Mon Sep 17 00:00:00 2001 From: peaklabs-dev <122374094+peaklabs-dev@users.noreply.github.com> Date: Mon, 9 Nov 2026 19:46:22 +0100 Subject: [PATCH 2/2] refactor(scripts): align the manifest cleanup with the images - restructure the listing of untagged manifests for ShellCheck SC2015 - expand a group the way shfmt formats it - keep the pull request images of the variants VARIANTS lists, none here --- scripts/clean-manifests.sh | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/scripts/clean-manifests.sh b/scripts/clean-manifests.sh index d5bf414eb6..0b75772506 100755 --- a/scripts/clean-manifests.sh +++ b/scripts/clean-manifests.sh @@ -4,6 +4,7 @@ set -euo pipefail OPTION="$*" LIMIT="${2:-}" IMAGE=coollabsio/coolify +VARIANTS="" KEEP_TAG_PATTERN='^(latest|preview|main|nightly|v?[0-9]+\.[0-9]+\.[0-9]+(-(alpha|beta|rc)\.[0-9]+)?)$' KEEP_TAG_EXCEPTIONS=v3,4.0.0-beta.420.1,4.0.0-beta.420.2,4.0.0-beta.420.3,4.0.0-beta.420.4,4.0.0-beta.420.5,4.0.0-beta.420.6,4.0.0-beta.420.7,4.0.0-beta.420.8,4.0.0-beta.420.9,4.0.0-beta.420.10 KEEP_NIGHTLY_DAYS=14 @@ -105,9 +106,11 @@ read_dockerhub_untagged_manifests() { url="$base" : > "$WORK_DIR/listing.tsv" while [ -n "$url" ]; do - page="$(curl -sSf --retry 3 -H "Authorization: Bearer $hub" "$url")" \ - && jq -r '.manifests[] | [.manifest_digest, .media_type, (.tags // [] | join(",")), .last_pushed, (if (.media_type // "" | test("index|list")) then .size else .total_size end), ([.os, .arch] | map(select(. != null and . != "")) | join("/"))] | @tsv' <<< "$page" >> "$WORK_DIR/listing.tsv" \ - || { warn "the undocumented manifests listing of the Docker Hub API failed, the untagged manifests that no tag references wait for a later run"; return; } + if ! page="$(curl -sSf --retry 3 -H "Authorization: Bearer $hub" "$url")" \ + || ! jq -r '.manifests[] | [.manifest_digest, .media_type, (.tags // [] | join(",")), .last_pushed, (if (.media_type // "" | test("index|list")) then .size else .total_size end), ([.os, .arch] | map(select(. != null and . != "")) | join("/"))] | @tsv' <<< "$page" >> "$WORK_DIR/listing.tsv"; then + warn "the undocumented manifests listing of the Docker Hub API failed, the untagged manifests that no tag references wait for a later run" + return + fi key="$(jq -r 'select(.manifests | length > 0) | .last_evaluated_key // empty' <<< "$page")" url="${key:+$base&last_evaluated_key=$(jq -rn --arg key "$key" '$key | @uri')}" done @@ -121,8 +124,9 @@ select_kept_tags() { { cut -f 3 "$WORK_DIR/ghcr-active.tsv" | tr ',' '\n' && cut -f 3 "$WORK_DIR/dockerhub.tsv"; } | sed '/^$/d' | sort -u > "$WORK_DIR/tags.txt" git ls-remote --tags "https://github.com/$IMAGE.git" | sed -n 's|.*refs/tags/||p' | sed 's/\^{}$//; p; s/^v//' > "$WORK_DIR/keep.txt" \ || die "could not list the git tags of github.com/$IMAGE" - gh pr list --repo "$IMAGE" --state open --limit 1000 --json number --jq '.[] | "pr-\(.number)"' >> "$WORK_DIR/keep.txt" \ + gh pr list --repo "$IMAGE" --state open --limit 1000 --json number --jq '.[] | "pr-\(.number)"' > "$WORK_DIR/pull-requests.txt" \ || die "gh could not list the open pull requests of $IMAGE" + awk -v variants="$VARIANTS" '{ print; n = split(variants, variant, ","); for (i = 1; i <= n; i++) print $0 "-" variant[i] }' "$WORK_DIR/pull-requests.txt" >> "$WORK_DIR/keep.txt" tr ',' '\n' <<< "$KEEP_TAG_EXCEPTIONS" >> "$WORK_DIR/keep.txt" cutoff="$(jq -nr --argjson days "$KEEP_NIGHTLY_DAYS" 'now - $days * 86400 | strftime("%Y%m%d")')" { @@ -317,7 +321,10 @@ delete_dockerhub_manifest() { local token status token="$(registry_token docker.io pull,push,delete)" status="$(curl -sS --retry 3 -o /dev/null -w '%{http_code}' --head -H "Authorization: Bearer $token" -H "Accept: $MANIFEST_TYPES" "https://registry-1.docker.io/v2/$IMAGE/manifests/$1")" - [ "$status" = 200 ] || { echo "$status"; return; } + [ "$status" = 200 ] || { + echo "$status" + return + } while status="$(curl -sS --retry 3 -o /dev/null -w '%{http_code}' -X DELETE -H "Authorization: Bearer $token" "https://registry-1.docker.io/v2/$IMAGE/manifests/$1")" && [ "$status" = 429 ]; do sleep 60 token="$(registry_token docker.io pull,push,delete)"