Skip to content

Bump scrapy from 2.11.1 to 2.11.2 #15

Bump scrapy from 2.11.1 to 2.11.2

Bump scrapy from 2.11.1 to 2.11.2 #15

Workflow file for this run

name: Build Docker container
on:
push:
branches:
- 'main'
tags:
- 'v[0-9]+.[0-9]+.[0-9]+'
pull_request:
branches:
- 'main'
jobs:
container:
runs-on: ubuntu-latest
steps:
- name: Docker meta
id: meta
uses: docker/metadata-action@v4
with:
images: ghcr.io/q-m/scrapyd-k8s-spider-example
tags: |
type=ref,event=branch
type=ref,event=pr
type=semver,pattern={{version}}
type=sha
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
if: ${{ github.event_name != 'pull_request' }}
with:
registry: ghcr.io
username: ${{ github.repository_owner}}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build for current architecture
id: build
uses: docker/build-push-action@v5
with:
push: false
load: true
tags: spider:latest
- name: Get spiders
id: spiders
run: |
SPIDERS=`docker run --rm spider:latest scrapy list | tr '\n' ',' | sed 's/,$//'`
echo "spiders=$SPIDERS" >> "$GITHUB_OUTPUT"
- name: Rebuild and push
if: ${{ github.event_name != 'pull_request' }}
uses: docker/build-push-action@v5
with:
platforms: linux/amd64,linux/arm64
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: |
${{ steps.meta.outputs.labels }}
org.scrapy.project=example
org.scrapy.spiders=${{ steps.spiders.outputs.spiders }}