Skip to content

Commit e26cf7a

Browse files
committed
WIP
1 parent 0ccd813 commit e26cf7a

File tree

1 file changed

+16
-70
lines changed

1 file changed

+16
-70
lines changed

.github/workflows/release.yml

Lines changed: 16 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ on:
55
tags:
66
- "ccf-[56].*"
77
workflow_dispatch:
8+
pull_request:
89

910
permissions:
1011
contents: write
@@ -55,7 +56,7 @@ jobs:
5556
set -ex
5657
set -o pipefail
5758
python ./scripts/extract-release-notes.py --target-git-version --describe-path-changes "./samples/constitution" | tee rel-notes.md
58-
- name: "Upload .deb Package"
59+
- name: "Upload Release Notes"
5960
uses: actions/upload-artifact@v4
6061
with:
6162
name: relnotes
@@ -67,17 +68,10 @@ jobs:
6768
strategy:
6869
matrix:
6970
platform:
70-
- name: virtual
71-
os: ubuntu
72-
image: ghcr.io/microsoft/ccf/ci/default:build-14-01-2025
73-
test_filter: "benchmark|unit"
74-
- name: snp
75-
os: ubuntu
76-
image: ghcr.io/microsoft/ccf/ci/default:build-14-01-2025
7771
- name: virtual
7872
os: azure-linux
7973
image: mcr.microsoft.com/azurelinux/base/core:3.0
80-
test_filter: "benchmark|unit|lts"
74+
test_filter: "benchmark|unit"
8175
- name: snp
8276
os: azure-linux
8377
image: mcr.microsoft.com/azurelinux/base/core:3.0
@@ -89,7 +83,6 @@ jobs:
8983

9084
steps:
9185
- name: "Checkout dependencies"
92-
if: ${{ matrix.platform.os == 'azure-linux' }}
9386
shell: bash
9487
run: |
9588
gpg --import /etc/pki/rpm-gpg/MICROSOFT-RPM-GPG-KEY
@@ -101,7 +94,6 @@ jobs:
10194
fetch-depth: 0
10295

10396
- name: "Install dependencies"
104-
if: ${{ matrix.platform.os == 'azure-linux' }}
10597
shell: bash
10698
run: |
10799
set -ex
@@ -117,16 +109,6 @@ jobs:
117109
cmake -GNinja -DCOMPILE_TARGET=${{ matrix.platform.name }} -DCLIENT_PROTOCOLS_TEST=ON -DCMAKE_BUILD_TYPE=Release ..
118110
ninja -v | tee build.log
119111
120-
- name: "Install Extended Testing Tools"
121-
if: ${{ matrix.platform.os == 'ubuntu' && matrix.platform.name == 'virtual' }}
122-
run: |
123-
set -ex
124-
sudo apt-get -y update
125-
sudo apt install ansible -y
126-
cd getting_started/setup_vm
127-
ansible-playbook ccf-extended-testing.yml
128-
shell: bash
129-
130112
- name: "Test ${{ matrix.platform.name }}"
131113
if: "${{ matrix.platform.name == 'virtual' }}"
132114
run: |
@@ -143,37 +125,19 @@ jobs:
143125
./tests.sh --timeout 360 --output-on-failure -LE "suite|${{ matrix.platform.test_filter }}"
144126
shell: bash
145127

146-
- name: "Upload logs for ${{ matrix.platform.os }}-${{ matrix.platform.name }}"
128+
- name: "Upload logs for ${{ matrix.platform.name }}"
147129
if: success() || failure()
148130
uses: actions/upload-artifact@v4
149131
with:
150-
name: logs-${{ matrix.platform.os }}-${{ matrix.platform.name }}
132+
name: logs-${{ matrix.platform.name }}
151133
path: |
152134
build/workspace/*/*.config.json
153135
build/workspace/*/out
154136
build/workspace/*/err
155137
build/workspace/*.ledger/*
156138
if-no-files-found: ignore
157139

158-
- name: "Make .deb Package"
159-
if: "${{ matrix.platform.os == 'ubuntu' }}"
160-
id: make_deb
161-
run: |
162-
set -ex
163-
set -o pipefail
164-
cd build
165-
cmake -L .. 2>/dev/null | grep CMAKE_INSTALL_PREFIX: | cut -d = -f 2 > /tmp/install_prefix
166-
cpack -V -G DEB
167-
INITIAL_PKG=`ls *.deb`
168-
CCF_GITHUB_PKG=${INITIAL_PKG//\~/_}
169-
if [[ "$INITIAL_PKG" != "$CCF_GITHUB_PKG" ]]; then
170-
mv $INITIAL_PKG $CCF_GITHUB_PKG
171-
fi
172-
echo "name=$CCF_GITHUB_PKG" >> $GITHUB_OUTPUT
173-
shell: bash
174-
175140
- name: "Make .rpm (devel) Package"
176-
if: "${{ matrix.platform.os == 'azure-linux' }}"
177141
id: make_rpm_devel
178142
run: |
179143
set -ex
@@ -190,7 +154,6 @@ jobs:
190154
shell: bash
191155

192156
- name: "Make .rpm (run) Package"
193-
if: "${{ matrix.platform.os == 'azure-linux' }}"
194157
id: make_rpm_run
195158
run: |
196159
set -ex
@@ -211,16 +174,7 @@ jobs:
211174
echo "name=$CCF_GITHUB_PKG" >> $GITHUB_OUTPUT
212175
shell: bash
213176

214-
- name: "Install CCF Debian package"
215-
if: "${{ matrix.platform.os == 'ubuntu' }}"
216-
run: |
217-
set -ex
218-
cd build
219-
sudo apt -y install ./${{ steps.make_deb.outputs.name }}
220-
shell: bash
221-
222-
- name: "Install CCF RPM package"
223-
if: "${{ matrix.platform.os == 'azure-linux' }}"
177+
- name: "Install CCF package"
224178
run: |
225179
set -ex
226180
cd build
@@ -251,43 +205,34 @@ jobs:
251205
./tests/test_install_build.sh -DCOMPILE_TARGET=${{ matrix.platform.name }}
252206
shell: bash
253207

254-
- name: "Upload .deb Package"
255-
if: "${{ matrix.platform.os == 'ubuntu' }}"
256-
uses: actions/upload-artifact@v4
257-
with:
258-
name: pkg-${{ matrix.platform.os }}-${{ matrix.platform.name }}
259-
path: build/${{ steps.make_deb.outputs.name }}
260-
261208
- name: "Upload .rpm Package"
262-
if: "${{ matrix.platform.os == 'azure-linux' }}"
263209
uses: actions/upload-artifact@v4
264210
with:
265-
name: pkg-${{ matrix.platform.os }}-${{ matrix.platform.name }}
211+
name: pkg-${{ matrix.platform.name }}
266212
path: build/${{ steps.make_rpm_run.outputs.name }}
267213

268214
- name: "Upload -devel.rpm Package"
269-
if: "${{ matrix.platform.os == 'azure-linux' }}"
270215
uses: actions/upload-artifact@v4
271216
with:
272-
name: pkg-${{ matrix.platform.os }}-${{ matrix.platform.name }}-devel
217+
name: pkg-${{ matrix.platform.name }}-devel
273218
path: build/${{ steps.make_rpm_devel.outputs.name }}
274219

275220
- name: "Upload Compatibility Report"
276-
if: "${{ matrix.platform.os == 'ubuntu' && matrix.platform.name == 'virtual' }}"
221+
if: "${{ matrix.platform.name == 'virtual' }}"
277222
uses: actions/upload-artifact@v4
278223
with:
279224
name: compatibility
280225
path: build/compatibility_report.json
281226

282227
- name: "Upload TLS Report"
283-
if: "${{ matrix.platform.os == 'ubuntu' && matrix.platform.name == 'virtual' }}"
228+
if: "${{ matrix.platform.name == 'virtual' }}"
284229
uses: actions/upload-artifact@v4
285230
with:
286231
name: tls
287232
path: build/tls_report.html
288233

289234
- name: "Build Python Wheel"
290-
if: "${{ matrix.platform.os == 'ubuntu' && matrix.platform.name == 'virtual' }}"
235+
if: "${{ matrix.platform.name == 'virtual' }}"
291236
id: build_wheel
292237
run: |
293238
set -ex
@@ -301,14 +246,14 @@ jobs:
301246
shell: bash
302247

303248
- name: "Upload Python Wheel"
304-
if: "${{ matrix.platform.os == 'ubuntu' && matrix.platform.name == 'virtual' }}"
249+
if: "${{ matrix.platform.name == 'virtual' }}"
305250
uses: actions/upload-artifact@v4
306251
with:
307252
name: wheel
308253
path: python/${{ steps.build_wheel.outputs.name }}
309254

310255
- name: "Build TS Package"
311-
if: "${{ matrix.platform.os == 'ubuntu' && matrix.platform.name == 'virtual' }}"
256+
if: "${{ matrix.platform.name == 'virtual' }}"
312257
id: build_tstgz
313258
run: |
314259
set -ex
@@ -323,7 +268,7 @@ jobs:
323268
shell: bash
324269

325270
- name: "Upload TS Package"
326-
if: "${{ matrix.platform.os == 'ubuntu' && matrix.platform.name == 'virtual' }}"
271+
if: "${{ matrix.platform.name == 'virtual' }}"
327272
uses: actions/upload-artifact@v4
328273
with:
329274
name: tstgz
@@ -376,7 +321,8 @@ jobs:
376321
set -ex
377322
CCF_VERSION=${{ github.ref_name }}
378323
CCF_VERSION=${CCF_VERSION#ccf-}
379-
gh release create --title $CCF_VERSION --draft --notes-file rel-notes.md ${{ github.ref_name }} pkg/* wheel/*.whl tstgz/*.tgz sbom/* tls_report.html compatibility_report.json
324+
echo "Remove me"
325+
# gh release create --title $CCF_VERSION --draft --notes-file rel-notes.md ${{ github.ref_name }} pkg/* wheel/*.whl tstgz/*.tgz sbom/* tls_report.html compatibility_report.json
380326
shell: bash
381327
env:
382328
GH_TOKEN: ${{ github.token }}

0 commit comments

Comments
 (0)