Skip to content

Commit 24bce32

Browse files
committed
Move debos build into separate workflow file
Start moving the build logic into separated files to copy the method of meta-qcom to run PR builds/tests with repo secrets. Signed-off-by: Matt Hart <[email protected]>
1 parent bd3f7f5 commit 24bce32

File tree

3 files changed

+51
-11
lines changed

3 files changed

+51
-11
lines changed

.github/workflows/build-on-pr.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Build on PR
2+
3+
on:
4+
pull_request:
5+
6+
permissions:
7+
checks: write
8+
pull-requests: write
9+
contents: read
10+
packages: read
11+
12+
jobs:
13+
event-file:
14+
name: "Upload event file"
15+
runs-on: ubuntu-latest
16+
steps:
17+
- name: Upload
18+
uses: actions/upload-artifact@v4
19+
with:
20+
name: Event File
21+
path: ${{ github.event_path }}
22+
build-pr:
23+
uses: ./.github/workflows/debos.yml
24+

.github/workflows/daily.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: Daily Build
2+
3+
on:
4+
# run daily at 8:30am
5+
schedule:
6+
- cron: '30 8 * * *'
7+
# allow manual runs
8+
workflow_dispatch:
9+
10+
11+
permissions:
12+
checks: write
13+
pull-requests: write
14+
contents: read
15+
packages: read
16+
17+
jobs:
18+
build-daily:
19+
uses: ./.github/workflows/debos.yml

.github/workflows/debos.yml

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,11 @@
11
name: Build debos recipe
22

33
on:
4-
# run on pull requests to the main branch
5-
pull_request:
6-
branches: [main]
7-
# run on pushes to the main branch
8-
push:
9-
branches: [main]
10-
# run daily at 8:30am
11-
schedule:
12-
- cron: '30 8 * * *'
13-
# allow manual runs
14-
workflow_dispatch:
4+
workflow_call:
5+
outputs:
6+
artifacts_url:
7+
description: "URL to retrieve build artifacts"
8+
value: ${{ jobs.build-debos.outputs.url }}
159

1610
# only need permission to read repository; implicitely set all other
1711
# permissions to none
@@ -31,6 +25,8 @@ concurrency:
3125

3226
jobs:
3327
build-debos:
28+
outputs:
29+
url: ${{ steps.upload_artifacts.outputs.url }}
3430
runs-on: [self-hosted, arm64, debbuilder]
3531
container:
3632
image: debian:trixie
@@ -98,6 +94,7 @@ jobs:
9894
debos-recipes/qualcomm-linux-debian-flash.yaml
9995
10096
- name: Upload artifacts to fileserver space for builds
97+
id: upload_artifacts
10198
run: |
10299
set -ux
103100
# curl will be used to talk to fileserver; should be installed by

0 commit comments

Comments
 (0)