🕷️ The BEST Web Scraping framework that handles everything from a single request to a full-scale crawl! Don't be shy, join here: https://discord.gg/EMgGbDceNQ and follow here for daily tips and tricks: https://x.com/Scrapling_dev
Python aiai-scrapingautomationcrawlercrawlingcrawling-pythondatadata-extractionmcpmcp-serverplaywrightpythonscrapingselectorsstealthweb-scraperweb-scrapingweb-scraping-pythonwebscrapingxpath
ci(docker): tag images with the release version on merge (#384)
JanRKf293d83fdade
diff --git a/.github/workflows/docker-build.yml b/.github/workflows/docker-build.ymlindex 2951852..ba4d6e9 100644--- a/.github/workflows/docker-build.yml+++ b/.github/workflows/docker-build.yml@@ -19,6 +19,7 @@ env:jobs:build-and-push:runs-on: ubuntu-latest+ if: ${{ github.event_name == 'workflow_dispatch' || github.event.pull_request.merged == true }}permissions:contents: readpackages: write@@ -27,6 +28,19 @@ jobs:- name: Checkout repositoryuses: actions/checkout@v6+ - name: Extract release version from PR title+ id: version+ if: ${{ github.event_name == 'pull_request' && github.event.pull_request.merged == true }}+ env:+ PR_TITLE: ${{ github.event.pull_request.title }}+ run: |+ if [[ $PR_TITLE =~ ^v ]]; then+ echo "version=$PR_TITLE" >> "$GITHUB_OUTPUT"+ echo "Release version detected from PR title: $PR_TITLE"+ else+ echo "PR title '$PR_TITLE' is not a version; skipping semver tags."+ fi+- name: Set up Docker Buildxuses: docker/setup-buildx-action@v3with:@@ -56,9 +70,8 @@ jobs:tags: |type=ref,event=branchtype=ref,event=pr- type=semver,pattern={{version}}- type=semver,pattern={{major}}.{{minor}}- type=semver,pattern={{major}}+ type=semver,pattern={{version}},value=${{ steps.version.outputs.version }},enable=${{ steps.version.outputs.version != '' }}+ type=semver,pattern={{major}}.{{minor}},value=${{ steps.version.outputs.version }},enable=${{ steps.version.outputs.version != '' }}type=raw,value=latest,enable={{is_default_branch}}labels: |org.opencontainers.image.title=Scrapling@@ -70,6 +83,7 @@ jobs:org.opencontainers.image.documentation=https://scrapling.readthedocs.io/en/latest/- name: Build and push Docker image+ id: builduses: docker/build-push-action@v6with:context: .