From 4c83472040dbbf2ae41ae068b4566bf2cf40813f Mon Sep 17 00:00:00 2001 From: joocer Date: Mon, 15 Jul 2024 23:51:51 +0100 Subject: [PATCH] test --- .github/workflows/test.yml | 28 ++++++++++------------------ 1 file changed, 10 insertions(+), 18 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 0bc12f2f..9ffaba5d 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -5,33 +5,25 @@ on: [push, pull_request] jobs: build: runs-on: ubuntu-latest - container: quay.io/pypa/manylinux2014_x86_64@sha256:7faa424c478d774a3ac17baacb5fa6b59e7c75dae47a6cb84f23df757d83469e strategy: matrix: - python-version: [cp39-cp39, cp310-cp310, cp311-cp311, cp312-cp312] + python-version: [3.9, 3.10, 3.11, 3.12] steps: - name: Checkout repository uses: actions/checkout@v4 - - name: Install rust toolchain - uses: actions-rs/toolchain@v1 - with: - toolchain: stable - override: true - - - name: Install Python package dependencies - run: /opt/python/${{ matrix.python-version }}/bin/python -m pip install --upgrade cython wheel numpy setuptools_rust - - - name: Build binary wheel - run: /opt/python/${{ matrix.python-version }}/bin/python setup.py bdist_wheel - - - name: Apply auditwheel for manylinux wheel - run: auditwheel repair -w dist dist/* + - name: Build Docker image + run: docker build -t my-custom-image . - - name: Remove linux wheel - run: rm dist/*-linux_x86_64.whl + - name: Build for Python ${{ matrix.python-version }} + run: | + docker run --rm -v ${{ github.workspace }}:/workspace my-custom-image /bin/bash -c " + python${{ matrix.python-version }} -m pip install --upgrade setuptools wheel && \ + python${{ matrix.python-version }} setup.py bdist_wheel && \ + auditwheel repair -w dist dist/* && \ + rm dist/*-linux_x86_64.whl" - name: Archive dist artifacts uses: actions/upload-artifact@v2