|
19 | 19 | # TODO automation trigger
|
20 | 20 |
|
21 | 21 | jobs:
|
22 |
| - |
23 | 22 | build:
|
24 |
| - |
25 |
| - runs-on: [self-hosted, Linux, platform-builder-Rocky-8.6] |
26 |
| - # TODO which manylinux do we want to build for? 2014? 2_28? 2_34? Matrix? |
27 |
| - container: wheelmaker_2_28:0.1 |
28 |
| - |
29 | 23 | name: Build manylinux_2_28
|
30 |
| - |
31 |
| - steps: |
32 |
| - # TODO which project do we build odc wheel from -- this, or some bundle? Or can we obtain the compiled eckit artifact somehow? |
33 |
| - - run: git clone --branch develop --depth=1 https://github.com/ecmwf/eckit.git /src/eckit |
34 |
| - - run: /buildscripts/compile.sh ./eckit/python_wrapper/buildconfig |
35 |
| - - uses: actions/checkout@v2 |
36 |
| - - run: /buildscripts/compile.sh ./metkit/python_wrapper/buildconfig |
37 |
| - |
38 |
| - ################################################################ |
39 |
| - - run: /buildscripts/wheel-linux.sh ./metkit/python_wrapper/buildconfig 3.11 |
40 |
| - - uses: actions/upload-artifact@v4 |
41 |
| - name: Upload wheel 3.11 |
42 |
| - with: |
43 |
| - name: wheel-manylinux2_28-3.11 |
44 |
| - path: /build/wheel/*.whl |
45 |
| - |
46 |
| - # TODO other python versions, once the above is correct. |
47 |
| - # NOTE if Matrix, then break into (compile & upload) ; (wheel & upload)[matix] steps |
48 |
| - |
49 |
| - test: |
50 |
| - |
51 |
| - needs: build |
52 |
| - strategy: |
53 |
| - fail-fast: false |
54 |
| - matrix: |
55 |
| - python-version: ["3.11"] # ["3.8", "3.9", "3.10", "3.11", "3.12"] # TODO enable |
56 |
| - |
57 |
| - name: Test with ${{ matrix.python-version }} |
58 | 24 | runs-on: [self-hosted, Linux, platform-builder-Rocky-8.6]
|
59 |
| - container: wheelmaker_2_28:0.1 |
| 25 | + # TODO which manylinux do we want to build for? 2014? 2_28? 2_34? Matrix? |
| 26 | + container: |
| 27 | + image: eccr.ecmwf.int/wheelmaker/2_28:0.10 |
| 28 | + credentials: |
| 29 | + username: ${{ secrets.ECMWF_DOCKER_REGISTRY_USERNAME }} |
| 30 | + password: ${{ secrets.ECMWF_DOCKER_REGISTRY_ACCESS_TOKEN }} |
60 | 31 | steps:
|
61 |
| - - uses: actions/checkout@v2 |
62 |
| - - uses: actions/download-artifact@v4 |
63 |
| - with: |
64 |
| - name: wheel-manylinux2_28-${{ matrix.python-version }} |
65 |
| - - run: /buildscripts/test-wheel.sh ${{ matrix.python-version }} |
66 |
| - |
67 |
| -# TODO enable and test |
68 |
| -# deploy: |
69 |
| -# |
70 |
| -# if: ${{ github.ref_type == 'tag' || github.event_name == 'release' }} |
71 |
| -# needs: [test, build] |
72 |
| -# strategy: |
73 |
| -# fail-fast: false |
74 |
| -# matrix: |
75 |
| -# python-version: ["3.11"] # ["3.8", "3.9", "3.10", "3.11", "3.12"] # TODO enable |
76 |
| -# |
77 |
| -# name: Deploy wheel ${{ matrix.python-version }} |
78 |
| -# runs-on: [self-hosted, Linux, platform-builder-Rocky-8.6] |
79 |
| -# container: wheelmaker_2_28:0.1 |
80 |
| -# steps: |
81 |
| -# - run: mkdir artifact-${{ matrix.python-version }} |
82 |
| -# - uses: actions/checkout@v2 |
83 |
| -# - uses: actions/download-artifact@v4 |
84 |
| -# with: |
85 |
| -# name: wheel-manylinux2_28-${{ matrix.python-version }} |
86 |
| -# path: artifact-${{ matrix.python-version }} |
87 |
| -# - run: | |
88 |
| -# /buildsripts/upload-twine.sh ${{ matrix.python-version }} |
89 |
| -# env: |
90 |
| -# TWINE_USERNAME: __token__ |
91 |
| -# TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }} |
| 32 | + # TODO convert this to be matrix-friendly. Note it's a bit tricky since |
| 33 | + # we'd ideally not reexecute the compile step multiple times, but it |
| 34 | + # (non-essentially) depends on a matrix-based step |
| 35 | + # NOTE we dont use action checkout because it doesnt cleanup after itself correctly |
| 36 | + - run: git clone --depth=1 --branch="${GITHUB_REF#refs/heads/}" https://github.com/$GITHUB_REPOSITORY /proj |
| 37 | + - run: cd /proj && /buildscripts/prepare_deps.sh ./python_wrapper/buildconfig 3.11 |
| 38 | + - run: cd /proj && /buildscripts/compile.sh ./python_wrapper/buildconfig |
| 39 | + - run: cd /proj && PYTHONPATH=/buildscripts /buildscripts/wheel-linux.sh ./python_wrapper/buildconfig 3.11 |
| 40 | + - run: cd /proj && /buildscripts/test-wheel.sh ./python_wrapper/buildconfig 3.11 /tmp/build/wheel/*whl |
| 41 | + - run: cd /proj && /buildscripts/upload-pypi.sh /tmp/build/wheel/*whl |
| 42 | + env: |
| 43 | + TWINE_USERNAME: __token__ |
| 44 | + TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }} |
| 45 | + # NOTE temporary thing until all the mess gets cleared |
| 46 | + - run: rm -rf ./* ./.git ./.github |
0 commit comments