From c144bd626aac308cc35e016aa97d99aa699087ce Mon Sep 17 00:00:00 2001 From: Robert James Hernandez Date: Mon, 27 Jan 2025 16:22:56 +0000 Subject: [PATCH 1/9] github: run openwrt-build container userid: 1001 I was expecting this to be 1000 like it is when I run the container locally but I guess inside github actions its actually 1001. --- .github/workflows/openwrt-build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/openwrt-build.yml b/.github/workflows/openwrt-build.yml index 97d921d4..9514015d 100644 --- a/.github/workflows/openwrt-build.yml +++ b/.github/workflows/openwrt-build.yml @@ -14,8 +14,8 @@ jobs: container: # Ubuntu 24.04 image: sarcasticadmin/openwrt-build@sha256:25ac9d0dd4eeaad1aaaa7c82c09e9ecc103c69224fc55eb9717c4cfb018a5281 - # Since user is ubuntu and gets 1000 from inside container - options: --user 1000 + # Since user is openwrt and gets 1001 from inside container + options: --user 1001 steps: - uses: actions/checkout@v1 with: From 8179a0b32095b7c0d7d773525309287e9d12373d Mon Sep 17 00:00:00 2001 From: Robert James Hernandez Date: Tue, 28 Jan 2025 06:29:31 +0000 Subject: [PATCH 2/9] github: secrets can no longer start with GITHUB* --- .github/workflows/trigger.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/trigger.yml b/.github/workflows/trigger.yml index 8e617110..d1ea7bb0 100644 --- a/.github/workflows/trigger.yml +++ b/.github/workflows/trigger.yml @@ -29,7 +29,7 @@ jobs: # is not a PR event REF=$(curl -sSf \ --url ${{ steps.pr-standardize-comment.outputs.url }} \ - --header 'Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}' \ + --header 'Authorization: Bearer ${{ secrets.SCALE_GITHUB_TOKEN }}' \ --header 'Content-Type: application/json' | jq -r '.head.ref' \ ) echo "subcomm=$SUBCOMM" >> $GITHUB_OUTPUT From 7cbd3ee811e7672ad97f11c69ef9a3fcce0ad5d7 Mon Sep 17 00:00:00 2001 From: Robert James Hernandez Date: Fri, 31 Jan 2025 01:32:02 +0000 Subject: [PATCH 3/9] github: comment issue template so instructions arent rendered --- .github/ISSUE_TEMPLATE.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md index 958ebb5b..46209e83 100644 --- a/.github/ISSUE_TEMPLATE.md +++ b/.github/ISSUE_TEMPLATE.md @@ -1,7 +1,11 @@ ## Description + ## Acceptance Criteria + From 31dc3a0c9ff916ca09b026228bd94c10ffffaf44 Mon Sep 17 00:00:00 2001 From: Robert James Hernandez Date: Fri, 31 Jan 2025 01:32:13 +0000 Subject: [PATCH 4/9] github: comment pr template so instructions arent rendered --- .github/PULL_REQUEST_TEMPLATE.md | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index d7ba677e..2325d830 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -1,15 +1,28 @@ ## Description of PR -Brief description of the PR + ## Previous Behavior + ## New Behavior + ## Tests -How was this PR tested? + From 096ac79a4907584bd511bdc0b531b6c6fd7c1f9a Mon Sep 17 00:00:00 2001 From: Robert James Hernandez Date: Fri, 31 Jan 2025 01:33:40 +0000 Subject: [PATCH 5/9] github: comment pr template so instructions arent rendered --- .github/PULL_REQUEST_TEMPLATE.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index 2325d830..c6b7edd4 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -2,6 +2,9 @@ ## Previous Behavior From d26eb1aabf6403a7a3115f5cbaca8f4b4d5d7868 Mon Sep 17 00:00:00 2001 From: Robert James Hernandez Date: Fri, 31 Jan 2025 01:34:31 +0000 Subject: [PATCH 6/9] github: use upload-artifact@v4 ahead of deprecation --- .github/workflows/openwrt-build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/openwrt-build.yml b/.github/workflows/openwrt-build.yml index 9514015d..a385a17c 100644 --- a/.github/workflows/openwrt-build.yml +++ b/.github/workflows/openwrt-build.yml @@ -28,7 +28,7 @@ jobs: cd openwrt TARGET=${{ matrix.target }} make templates build-img package 2>&1 | tee ${{ matrix.target }}-build.log - name: 'Upload openwrt build artifact tarball' - uses: actions/upload-artifact@v3.1.1 + uses: actions/upload-artifact@v4.6.0 with: name: ${{ matrix.target }}-openwrt-build-artifacts # Cant use relative pathing .. or . for artifacts action @@ -37,7 +37,7 @@ jobs: openwrt/build/artifacts/*.tar.gz retention-days: 30 - name: 'Upload openwrt build log' - uses: actions/upload-artifact@v3.1.1 + uses: actions/upload-artifact@v4.6.0 with: name: ${{ matrix.target }}-openwrt-buildlog path: | From 13ff32b04d7e53d7b8093ac0aa47b93ea80fdbc3 Mon Sep 17 00:00:00 2001 From: Robert James Hernandez Date: Fri, 31 Jan 2025 01:35:00 +0000 Subject: [PATCH 7/9] github: set compression to level 0 for tar.gz artifacts --- .github/workflows/openwrt-build.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/openwrt-build.yml b/.github/workflows/openwrt-build.yml index a385a17c..bc81cf84 100644 --- a/.github/workflows/openwrt-build.yml +++ b/.github/workflows/openwrt-build.yml @@ -36,6 +36,8 @@ jobs: path: | openwrt/build/artifacts/*.tar.gz retention-days: 30 + # Since we cant turn off compression set to lowest level + compression-level: 0 - name: 'Upload openwrt build log' uses: actions/upload-artifact@v4.6.0 with: From 1bc49459d4c3e1318067d12d6eb478be1e53aaaf Mon Sep 17 00:00:00 2001 From: Robert James Hernandez Date: Fri, 31 Jan 2025 01:39:55 +0000 Subject: [PATCH 8/9] github: ensure artifacts are always overwritten --- .github/workflows/openwrt-build.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/openwrt-build.yml b/.github/workflows/openwrt-build.yml index bc81cf84..928e1915 100644 --- a/.github/workflows/openwrt-build.yml +++ b/.github/workflows/openwrt-build.yml @@ -38,6 +38,10 @@ jobs: retention-days: 30 # Since we cant turn off compression set to lowest level compression-level: 0 + # rerunning jobs overwrites artifacts from previous runs + # this was the default behavior in v3.x + # ref: https://github.com/actions/upload-artifact/blob/v3.1.1/README.md?plain=1#L152 + overwrite: true - name: 'Upload openwrt build log' uses: actions/upload-artifact@v4.6.0 with: @@ -45,3 +49,4 @@ jobs: path: | openwrt/*build.log retention-days: 30 + overwrite: true From 03b364e00f70091c8b4efc15aca87607de420388 Mon Sep 17 00:00:00 2001 From: Robert James Hernandez Date: Sat, 1 Feb 2025 20:51:01 +0000 Subject: [PATCH 9/9] github: error when no files found --- .github/workflows/openwrt-build.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/openwrt-build.yml b/.github/workflows/openwrt-build.yml index 928e1915..4ee79ebd 100644 --- a/.github/workflows/openwrt-build.yml +++ b/.github/workflows/openwrt-build.yml @@ -42,6 +42,8 @@ jobs: # this was the default behavior in v3.x # ref: https://github.com/actions/upload-artifact/blob/v3.1.1/README.md?plain=1#L152 overwrite: true + # if we dont have images, scream loudly + if-no-files-found: "error" - name: 'Upload openwrt build log' uses: actions/upload-artifact@v4.6.0 with: @@ -50,3 +52,4 @@ jobs: openwrt/*build.log retention-days: 30 overwrite: true + if-no-files-found: "error"