Skip to content

chore(deps): lock file maintenance #688

chore(deps): lock file maintenance

chore(deps): lock file maintenance #688

Workflow file for this run

name: Workflow
on:
push:
branches: [ main ]
tags:
- v**
pull_request: { }
jobs:
validate-renovate-config:
uses: BlindfoldedSurgery/renovate-config/.github/workflows/validate.yml@main
check-commits:
uses: BlindfoldedSurgery/actions-releases/.github/workflows/commitizen-check.yml@v2
lint:
strategy:
matrix:
python-version: [ "3.13", "3.12", "3.11" ]
uses: BlindfoldedSurgery/actions-python/.github/workflows/lint.yml@v2
with:
python-version: ${{ matrix.python-version }}
test:
strategy:
matrix:
python-version: [ "3.13", "3.12", "3.11" ]
uses: BlindfoldedSurgery/actions-python/.github/workflows/test.yml@v2
with:
python-version: ${{ matrix.python-version }}
submit-coverage: ${{ matrix.python-version == '3.11' }}
tests-selector: not local
secrets:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
test-migrations-postgres:
strategy:
matrix:
postgres-version: [ "14", "15", "16" ]
runs-on: ubuntu-latest
container: flyway/flyway:10.20
services:
postgres:
image: postgres:${{ matrix.postgres-version }}
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
steps:
- uses: actions/checkout@v4
- run: flyway migrate -skipCheckForUpdate
working-directory: migrations/postgres
env:
FLYWAY_URL: jdbc:postgresql://postgres:5432/postgres
FLYWAY_USER: postgres
FLYWAY_PASSWORD: postgres
test-migrations-sqlite:
runs-on: ubuntu-latest
container: flyway/flyway:10.20
steps:
- uses: actions/checkout@v4
- run: flyway migrate -skipCheckForUpdate
working-directory: migrations/sqlite
extract-version:
runs-on: ubuntu-latest
outputs:
version: ${{ steps.extract.outputs.version }}
steps:
- uses: actions/checkout@v4
- name: Install Poetry
run: pip install poetry==1.8.4
- name: Use Poetry to read version
id: extract
run: |
VERSION=$(poetry version --short)
echo "version=$VERSION" >> "$GITHUB_OUTPUT"
build-migrations-container-image:
needs:
- extract-version
- lint
- test
- test-migrations-postgres
- test-migrations-sqlite
strategy:
matrix:
sql-dialect: [ "postgres", "sqlite" ]
platform: [ "arm64", "amd64" ]
uses: preparingforexams/actions-container/.github/workflows/build-image-kaniko.yml@v3
with:
additional-build-args: |
DIALECT=${{ matrix.sql-dialect }}
context: 'migrations'
digest-artifact-name: digests-${{ matrix.sql-dialect }}
runner-name-build: ${{ (matrix.platform == 'arm64') && 'warp-ubuntu-latest-arm64-2x' || 'ubuntu-latest' }}
push-image: ${{ startsWith(github.ref, 'refs/tags/v') }}
image-name: rate-limiter-migrations-${{ matrix.sql-dialect }}
version: ${{ needs.extract-version.outputs.version }}
tag-suffix: -${{ matrix.platform }}
merge-migrations-container-image:
if: success() && startsWith(github.ref, 'refs/tags/v')
needs:
- extract-version
- build-migrations-container-image
strategy:
matrix:
sql-dialect: [ "postgres", "sqlite" ]
uses: BlindfoldedSurgery/actions-container/.github/workflows/merge-manifests.yml@v3
with:
image-name: rate-limiter-migrations-${{ matrix.sql-dialect }}
tag: ${{ needs.extract-version.outputs.version }}
variant-digests: digests-${{ matrix.sql-dialect }}
publish-package:
uses: BlindfoldedSurgery/actions-python/.github/workflows/publish-package.yml@v2
needs:
- lint
- test
- test-migrations-postgres
- test-migrations-sqlite
if: success() && startsWith(github.ref, 'refs/tags/v')
with:
python-version: '3.11'
pypi-username: ${{ vars.PYPI_USERNAME }}
secrets:
pypi-password: ${{ secrets.PYPI_PASSWORD }}