From 36785bc6e00548e54cead5a01203b71b2ec62080 Mon Sep 17 00:00:00 2001 From: SvenBrnn Date: Fri, 30 May 2025 08:57:04 +0200 Subject: [PATCH] Update check-n8n-new-release.yml --- .github/workflows/check-n8n-new-release.yml | 24 ++++++++++++++++----- 1 file changed, 19 insertions(+), 5 deletions(-) diff --git a/.github/workflows/check-n8n-new-release.yml b/.github/workflows/check-n8n-new-release.yml index 37eae04..3540722 100644 --- a/.github/workflows/check-n8n-new-release.yml +++ b/.github/workflows/check-n8n-new-release.yml @@ -56,10 +56,24 @@ jobs: version_to_release=$(echo "${{ steps.ollama_release.outputs.last_version }}" | sed 's/ollama@//g') echo "version_to_release=$version_to_release" >> $GITHUB_OUTPUT - build-and-push-new-docker-image: + patch-dockerfile-and-push: needs: check-new-release if: ${{ needs.check-new-release.outputs.has_new_release == 'true' }} - uses: ./.github/workflows/build-and-push.yml - secrets: inherit - with: - ollama_version: ${{ needs.check-new-release.outputs.version_to_release }} + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Patch Dockerfile with new OLLAMA_VERSION + run: | + sed -i '1s/^ARG OLLAMA_VERSION=.*/ARG OLLAMA_VERSION=${{ needs.check-new-release.outputs.version_to_release }}/' Dockerfile + + - name: Commit and push changes + run: | + git config user.name "github-actions[bot]" + git config user.email "github-actions[bot]@users.noreply.github.com" + git add Dockerfile + git commit -m "chore: bump OLLAMA_VERSION to ${{ needs.check-new-release.outputs.version_to_release }}" + git push + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}