-
Notifications
You must be signed in to change notification settings - Fork 0
79 lines (61 loc) · 2.26 KB
/
docker-matrix.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
name: Matrix
on:
push:
branches:
- 'extend-matrix'
workflow_dispatch:
jobs:
Matrix:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
image-tag: ['3.12-slim-bullseye', '3.13.0rc1', '3.13.0rc1-slim', 'latest']
update-strategy: [locked-install, unlocked-install, latest-install]
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Docker Build
uses: docker/[email protected]
- name: Install and update dependencies
run: |
echo "Image tag: ${{ matrix.image-tag }}"
echo "Update strategy: ${{ matrix.update-strategy }}"
if [[ "${{ matrix.update-strategy }}" == "locked-install" ]]; then
echo "Running normal test with updated dependencies"
docker build --build-arg IMAGE_TAG=${{ matrix.image-tag }} --target test -t zephir-api2:test .
elif [[ "${{ matrix.update-strategy }}" == "unlocked-install" ]]; then
echo "Running normal test with updated dependencies"
docker build --build-arg IMAGE_TAG=${{ matrix.image-tag }} --target build-unlocked-test -t zephir-api2:test .
elif [[ "${{ matrix.update-strategy }}" == "latest-install" ]]; then
echo "Running normal test with updated dependencies"
docker build --build-arg IMAGE_TAG=${{ matrix.image-tag }} --target build-latest-test -t zephir-api2:test .
fi
generate-summary:
runs-on: ubuntu-latest
needs: Matrix
if: always()
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.x'
- name: Install Python dependencies
run: |
pip install requests pyyaml
- name: Generate Test Summary Report
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
REPO_OWNER: ${{ github.repository_owner }}
REPO_NAME: ${{ github.event.repository.name }}
WORKFLOW_RUN_ID: ${{ github.run_id }}
run: |
python summary.py > summary_report.txt
cat summary_report.txt
# - name: Upload Summary Report Artifact
# uses: actions/upload-artifact@v3
# with:
# name: test-summary-report
# path: summary_report.txt