diff --git a/.github/workflows/create-docker-image.yml b/.github/workflows/create-docker-image.yml index 5f5b30f..8a99dc1 100644 --- a/.github/workflows/create-docker-image.yml +++ b/.github/workflows/create-docker-image.yml @@ -23,6 +23,13 @@ jobs: - name: Checkout repository uses: actions/checkout@v4 + - name: Login to GitHub Container Registry + uses: docker/login-action@v2 + with: + registry: ${{ env.REGISTRY }} + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + - name: Install Dependencies uses: php-actions/composer@v6 with: @@ -31,23 +38,6 @@ jobs: progress: no args: --no-interaction --no-scripts --optimize-autoloader --ansi --ignore-platform-reqs - - name: Login to GitHub Container Registry - uses: docker/login-action@v2 - with: - registry: ${{ env.REGISTRY }} - username: ${{ github.actor }} - password: ${{ secrets.GITHUB_TOKEN }} - - # - name: Extract metadata (tags, labels) for Docker - # id: meta - # uses: docker/metadata-action@v5 - # with: - # labels: | - # org.opencontainers.image.title=Linter: PHPStan - # org.opencontainers.image.description=Lint with PHPStan & Liquid Light conventions - # org.opencontainers.image.vendor=Liquid Light - # images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} - - name: Build and push Docker image id: push uses: docker/build-push-action@v5 @@ -56,7 +46,8 @@ jobs: file: ${{ env.APP_PATH }}/../../Dockerfiles/Linter.dockerfile push: true labels: | - org.opencontainers.image.title=Linter: PHPStan - org.opencontainers.image.description=Lint with PHPStan & Liquid Light conventions - org.opencontainers.image.vendor=Liquid Light + org.opencontainers.image.title="Linter: PHPStan" + org.opencontainers.image.description="Lint with PHPStan & Liquid Light conventions" + org.opencontainers.image.vendor="Liquid Light" + org.opencontainers.image.source="https://github.com/liquidlight/linter" tags: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest