-
Notifications
You must be signed in to change notification settings - Fork 73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[PH] Create workflow to test backward compatibility of performance harness #1356
Changes from 41 commits
fe05332
c42f25b
f848de5
3a72042
2e90e39
cd69265
a2aa513
258fefc
99d2316
91cf4db
d42f0e7
58b0f32
5499dd0
ea37b69
3a0960e
441f5d3
e6ea54b
8cb771a
ff1a837
800a37e
c63042b
cb447c5
b7dea9b
bc46133
b2b22ab
265ee66
1a3ef7d
4f158de
8044aa1
de40f8a
7df3af7
cf7ae29
7be77cd
d46a16a
8eb51fc
477f62c
e0b3caa
495d6ea
0da3e7b
c3db754
4e19e36
56c0027
b59fede
bfa1685
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
@@ -0,0 +1,86 @@ | ||||||||||||||||||
name: "Build leap" | ||||||||||||||||||
|
||||||||||||||||||
on: | ||||||||||||||||||
workflow_dispatch: | ||||||||||||||||||
workflow_call: | ||||||||||||||||||
outputs: | ||||||||||||||||||
p: | ||||||||||||||||||
description: "Discovered Build Platforms" | ||||||||||||||||||
value: ${{ jobs.d.outputs.p }} | ||||||||||||||||||
|
||||||||||||||||||
permissions: | ||||||||||||||||||
packages: write | ||||||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think this should just be permissions:
packages: write
contents: read So I think as long as leap/.github/workflows/build.yaml Lines 34 to 38 in 4e19e36
Having packages: read in this location should cause all jobs in this workflow other then build-platform be read, where build-platform is write.
(btw your ph_backward_compatibility.yaml already does this) leap/.github/workflows/ph_backward_compatibility.yaml Lines 6 to 8 in 4e19e36
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Good catch. Slipped past when I was changing the others. I've corrected that now. |
||||||||||||||||||
contents: read | ||||||||||||||||||
|
||||||||||||||||||
defaults: | ||||||||||||||||||
run: | ||||||||||||||||||
shell: bash | ||||||||||||||||||
|
||||||||||||||||||
jobs: | ||||||||||||||||||
d: | ||||||||||||||||||
name: Discover Platforms | ||||||||||||||||||
runs-on: ubuntu-latest | ||||||||||||||||||
outputs: | ||||||||||||||||||
missing-platforms: ${{steps.discover.outputs.missing-platforms}} | ||||||||||||||||||
p: ${{steps.discover.outputs.platforms}} | ||||||||||||||||||
steps: | ||||||||||||||||||
- name: Discover Platforms | ||||||||||||||||||
id: discover | ||||||||||||||||||
uses: AntelopeIO/discover-platforms-action@v1 | ||||||||||||||||||
with: | ||||||||||||||||||
platform-file: .cicd/platforms.json | ||||||||||||||||||
password: ${{secrets.GITHUB_TOKEN}} | ||||||||||||||||||
package-name: builders | ||||||||||||||||||
|
||||||||||||||||||
build-platforms: | ||||||||||||||||||
name: Build Platforms | ||||||||||||||||||
needs: d | ||||||||||||||||||
if: needs.d.outputs.missing-platforms != '[]' | ||||||||||||||||||
strategy: | ||||||||||||||||||
fail-fast: false | ||||||||||||||||||
matrix: | ||||||||||||||||||
platform: ${{fromJSON(needs.d.outputs.missing-platforms)}} | ||||||||||||||||||
runs-on: ["self-hosted", "enf-x86-beefy"] | ||||||||||||||||||
permissions: | ||||||||||||||||||
packages: write | ||||||||||||||||||
contents: read | ||||||||||||||||||
steps: | ||||||||||||||||||
- name: Login to Container Registry | ||||||||||||||||||
uses: docker/login-action@v2 | ||||||||||||||||||
with: | ||||||||||||||||||
registry: ghcr.io | ||||||||||||||||||
username: ${{github.repository_owner}} | ||||||||||||||||||
password: ${{secrets.GITHUB_TOKEN}} | ||||||||||||||||||
- name: Build and push | ||||||||||||||||||
uses: docker/build-push-action@v3 | ||||||||||||||||||
with: | ||||||||||||||||||
push: true | ||||||||||||||||||
tags: ${{fromJSON(needs.d.outputs.p)[matrix.platform].image}} | ||||||||||||||||||
file: ${{fromJSON(needs.d.outputs.p)[matrix.platform].dockerfile}} | ||||||||||||||||||
|
||||||||||||||||||
Build: | ||||||||||||||||||
needs: [d, build-platforms] | ||||||||||||||||||
if: always() && needs.d.result == 'success' && (needs.build-platforms.result == 'success' || needs.build-platforms.result == 'skipped') | ||||||||||||||||||
strategy: | ||||||||||||||||||
fail-fast: false | ||||||||||||||||||
matrix: | ||||||||||||||||||
platform: [ubuntu20, ubuntu22] | ||||||||||||||||||
runs-on: ["self-hosted", "enf-x86-beefy"] | ||||||||||||||||||
container: ${{fromJSON(needs.d.outputs.p)[matrix.platform].image}} | ||||||||||||||||||
steps: | ||||||||||||||||||
- uses: actions/checkout@v3 | ||||||||||||||||||
with: | ||||||||||||||||||
submodules: recursive | ||||||||||||||||||
- name: Build | ||||||||||||||||||
id: build | ||||||||||||||||||
run: | | ||||||||||||||||||
# https://github.com/actions/runner/issues/2033 | ||||||||||||||||||
chown -R $(id -u):$(id -g) $PWD | ||||||||||||||||||
cmake -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr -GNinja | ||||||||||||||||||
cmake --build build | ||||||||||||||||||
tar -pc --exclude "*.o" build | zstd --long -T0 -9 > build.tar.zst | ||||||||||||||||||
- name: Upload builddir | ||||||||||||||||||
uses: AntelopeIO/upload-artifact-large-chunks-action@v1 | ||||||||||||||||||
with: | ||||||||||||||||||
name: ${{matrix.platform}}-build | ||||||||||||||||||
path: build.tar.zst |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since this job (that uses the reusable workflow) doesn't have a name it seems to show up as simply
build-base
in the GUI in various places. I'm a little surprises it doesn't inherit the callee workflow name. Maybe we could consider giving this a name (even justBuild
) to show up nicer.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated with name


Run Build Workflow
: