From df84afa627c2d91436654c167dac41e41bf2a9ba Mon Sep 17 00:00:00 2001 From: NxPKG <116948796+NxPKG@users.noreply.github.com> Date: Sat, 30 Mar 2024 23:16:58 +0600 Subject: [PATCH] Create build.yaml Signed-off-by: NxPKG <116948796+NxPKG@users.noreply.github.com> --- .github/workflows/build.yaml | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 .github/workflows/build.yaml diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml new file mode 100644 index 0000000..7f45a01 --- /dev/null +++ b/.github/workflows/build.yaml @@ -0,0 +1,29 @@ +name: Publish Docker image +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + +jobs: + push_to_registry: + name: Push Docker image to GitHub Packages + runs-on: ubuntu-latest + permissions: write-all + steps: + - name: Check out the repo + uses: actions/checkout@v2 + + - name: Log in to GitHub Docker Registry + uses: docker/login-action@v1 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + + - name: Build and push Docker image + uses: docker/build-push-action@v2 + with: + context: . + push: ${{ github.event_name == 'push' }} + tags: ghcr.io/${{ github.repository }}:latest