From 508d870e5bc8221f4ee85d95ddb23a8c7c2068c0 Mon Sep 17 00:00:00 2001 From: agentHits <140916359+agentHits@users.noreply.github.com> Date: Fri, 23 Oct 2026 16:08:39 -0400 Subject: [PATCH] ci(image): push the dev image with the package owner's token The image build after PR #77 compiled the image and then failed to push it: "denied: permission_denied: The requested installation does not exist". The package ghcr.io/agenthits/dokploy belongs to the agentHits account, and since this repository moved to the TaskFlow-Systems organization the job's GITHUB_TOKEN may no longer write to it. The package settings cannot fix that: "Manage Actions access" only offers repositories of the agentHits account. The login step now uses the repository secret GHCR_PUSH_TOKEN (a classic token of agentHits with write:packages) when it exists and falls back to GITHUB_TOKEN otherwise. The image name stays the same, so the dev server, the installer, update.sh and the panel's update dialog keep working unchanged. Co-Authored-By: Claude Opus 5.5 --- .github/workflows/agenthits-image.yml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/agenthits-image.yml b/.github/workflows/agenthits-image.yml index a191f1bd33c..720a7b3f420 100644 --- a/.github/workflows/agenthits-image.yml +++ b/.github/workflows/agenthits-image.yml @@ -72,8 +72,12 @@ jobs: uses: docker/login-action@v4 with: registry: ${{ env.REGISTRY }} - username: ${{ github.actor }} - password: ${{ secrets.GITHUB_TOKEN }} + # The image package belongs to the agentHits account, and a + # personal-account package cannot give Actions access to a + # repository of an organization, so GHCR refuses the job token here + # and the push needs a token of the package owner. + username: ${{ secrets.GHCR_PUSH_TOKEN && 'agentHits' || github.actor }} + password: ${{ secrets.GHCR_PUSH_TOKEN || secrets.GITHUB_TOKEN }} - name: Build and push image uses: docker/build-push-action@v7