From 6804a642620a0b3855970abe24139ff0ac3adefd Mon Sep 17 00:00:00 2001 From: Costas Papastathis Date: Thu, 22 Feb 2024 23:07:14 +0200 Subject: [PATCH] Generating dockerhub org name according to github repo owner (#888) * fix: Generating dockerhub org name according to github repo owner * adding comments back --- builder/.github/workflows/push-image.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/builder/.github/workflows/push-image.yml b/builder/.github/workflows/push-image.yml index a7360e0c..2fb04095 100644 --- a/builder/.github/workflows/push-image.yml +++ b/builder/.github/workflows/push-image.yml @@ -38,8 +38,9 @@ jobs: env: PAKETO_BUILDPACKS_DOCKERHUB_USERNAME: ${{ secrets.PAKETO_BUILDPACKS_DOCKERHUB_USERNAME }} PAKETO_BUILDPACKS_DOCKERHUB_PASSWORD: ${{ secrets.PAKETO_BUILDPACKS_DOCKERHUB_PASSWORD }} - DOCKERHUB_ORG: "paketobuildpacks" + GITHUB_REPOSITORY_OWNER: ${{ github.repository_owner }} run: | + DOCKERHUB_ORG="${GITHUB_REPOSITORY_OWNER/-/}" # translates 'paketo-buildpacks' to 'paketobuildpacks' # Strip off the Github org prefix from repo name # paketo-buildpacks/builder-with-some-name --> builder-with-some-name registry_repo=$(echo "${{ github.repository }}" | sed 's/^.*\///')