From f266282261bc1e4cf76d198436d77b1acf2c9468 Mon Sep 17 00:00:00 2001 From: Rik Berkelder Date: Thu, 16 Jan 2025 01:48:57 +0100 Subject: [PATCH] CI complete webhook --- .gitea/workflows/deploy.yml | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index e2e341e..9a2218b 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -7,6 +7,7 @@ jobs: steps: - name: Checkout uses: actions/checkout@v3 + - name: Docker install run: | export DEBIAN_FRONTEND=noninteractive @@ -21,21 +22,34 @@ jobs: tee /etc/apt/sources.list.d/docker.list > /dev/null apt-get update apt-get install -yqq docker-ce docker-ce-cli containerd.io + - name: Set up Docker Buildx uses: docker/setup-buildx-action@v3 + - name: Docker Login uses: docker/login-action@v3 with: registry: git.riksolo.com username: riksolo password: ${{secrets.CONTAINER_REGISTRY_TOKEN}} + - name: Set up node uses: actions/setup-node@v4 with: node-version: '20.x' + - run: npm i + - name: Build and push uses: docker/build-push-action@v6 with: push: true - tags: git.riksolo.com/riksolo/multi-scrobbler-now-playing:latest , git.riksolo.com/riksolo/multi-scrobbler-now-playing:${{github.sha}} \ No newline at end of file + tags: git.riksolo.com/riksolo/multi-scrobbler-now-playing:latest , git.riksolo.com/riksolo/multi-scrobbler-now-playing:${{github.sha}} + + - name: Completion webhook + if: ${{always()}} + continue-on-error: true + uses: fjogeleit/http-request-action@v1 + with: + url: ${{secrets.NODE_RED_WORKFLOW_COMPLETE_URL}} + data: '{"job": ${{toJSON(job)}}, "gitea": ${{toJSON(gitea)}}}'