@@ -213,56 +213,11 @@ jobs:
213213 name : fedora-38-latest
214214 path : pkg/fedora/out/x86_64
215215
216- build-f37 :
217- if : github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/')
218-
219- name : Build Fedora 37 package
220- runs-on : ubuntu-latest
221- needs : [lint, test]
222- container :
223- image : registry.fedoraproject.org/fedora:37
224- options : --security-opt seccomp=unconfined
225-
226- steps :
227- - name : Checkout code
228- uses : actions/checkout@v4
229-
230- - name : Install build dependencies
231- run : |
232- dnf distro-sync -y
233- dnf install -y rpmdevtools rpm-sign 'dnf-command(builddep)'
234- dnf builddep -y pkg/fedora/surface-dtx-daemon.spec
235-
236- - name : Build package
237- run : |
238- cd pkg/fedora
239- # Build the .rpm packages
240- ./makerpm
241-
242- - name : Sign packages
243- env :
244- GPG_KEY_ID : 56C464BAAC421453
245- GPG_KEY : ${{ secrets.LINUX_SURFACE_GPG_KEY }}
246- run : |
247- cd pkg/fedora/out/x86_64
248-
249- # import GPG key
250- echo "$GPG_KEY" | base64 -d | gpg --import --no-tty --batch --yes
251-
252- # sign package
253- rpm --resign *.rpm --define "_gpg_name $GPG_KEY_ID"
254-
255- - name : Upload artifacts
256- uses : actions/upload-artifact@v4
257- with :
258- name : fedora-37-latest
259- path : pkg/fedora/out/x86_64
260-
261216 release :
262217 if : github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/')
263218
264219 name : Publish release
265- needs : [build-bin, build-deb, build-f39, build-f38, build-f37 ]
220+ needs : [build-bin, build-deb, build-f39, build-f38]
266221 runs-on : ubuntu-latest
267222
268223 steps :
@@ -290,12 +245,6 @@ jobs:
290245 name : fedora-38-latest
291246 path : fedora-38-latest
292247
293- - name : Download Fedora 37 artifacts
294- uses : actions/download-artifact@v4
295- with :
296- name : fedora-37-latest
297- path : fedora-37-latest
298-
299248 - name : Upload assets
300249 uses : svenstaro/upload-release-action@v2
301250 with :
@@ -462,56 +411,3 @@ jobs:
462411 git add .
463412 git commit -m "Update Fedora 38 DTX daemon"
464413 git push --set-upstream origin "${update_branch}"
465-
466- repo-f37 :
467- name : Update Fedora 37 package repository
468- needs : [release]
469- runs-on : ubuntu-latest
470- container :
471- image : registry.fedoraproject.org/fedora:37
472- options : --security-opt seccomp=unconfined
473- steps :
474- - name : Install dependencies
475- run : |
476- dnf install -y git findutils
477-
478- - name : Download artifacts
479- uses : actions/download-artifact@v4
480- with :
481- name : fedora-37-latest
482- path : fedora-37-latest
483-
484- - name : Update repository
485- env :
486- SURFACEBOT_TOKEN : ${{ secrets.LINUX_SURFACE_BOT_TOKEN }}
487- BRANCH_STAGING : u/staging
488- GIT_REF : ${{ github.ref }}
489- run : |
490- repo="https://surfacebot:${SURFACEBOT_TOKEN}@github.com/linux-surface/repo.git"
491-
492- # clone package repository
493- git clone -b "${BRANCH_STAGING}" "${repo}" repo
494-
495- # copy packages
496- cp fedora-37-latest/* repo/fedora/f37
497- cd repo/fedora/f37
498-
499- # parse git tag from ref
500- GIT_TAG=$(echo $GIT_REF | sed 's|^refs/tags/||g')
501-
502- # convert packages into references
503- for pkg in $(find . -name '*.rpm'); do
504- echo "surface-dtx-daemon:$GIT_TAG/$(basename $pkg)" > $pkg.blob
505- rm $pkg
506- done
507-
508- # set git identity
509- git config --global user.email "[email protected] " 510- git config --global user.name "surfacebot"
511-
512- # commit and push
513- update_branch="${BRANCH_STAGING}-$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1)"
514- git checkout -b "${update_branch}"
515- git add .
516- git commit -m "Update Fedora 37 DTX daemon"
517- git push --set-upstream origin "${update_branch}"
0 commit comments