[openwrt/openwrt] CI: move logs/ to GITHUB_WORKSPACE

LEDE Commits lede-commits at lists.infradead.org
Wed Mar 9 05:24:52 PST 2022


aparcar pushed a commit to openwrt/openwrt.git, branch master:
https://git.openwrt.org/a5eeac8033786a7a04b7569175e41e415b6579c0

commit a5eeac8033786a7a04b7569175e41e415b6579c0
Author: Paul Spooren <mail at aparcar.org>
AuthorDate: Wed Mar 9 13:30:21 2022 +0100

    CI: move logs/ to GITHUB_WORKSPACE
    
    Artifacts can only be uploaded from inside the GITHUB_WORKSPACE. While
    the Linux CI jobs run inside that per default, a special case-sensitive
    mount outside the GITHUB_WORKSPACE is used for macOS builds.
    
    To make log artifacts work for both macOS and Linux, move logs/ folder
    to GITHUB_WORKSPACE on failures.
    
    Signed-off-by: Paul Spooren <mail at aparcar.org>
---
 .github/workflows/tools.yml | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/.github/workflows/tools.yml b/.github/workflows/tools.yml
index 153db73625..76cbd30db7 100644
--- a/.github/workflows/tools.yml
+++ b/.github/workflows/tools.yml
@@ -121,9 +121,14 @@ jobs:
           cd "$WORKPATH"
           make tools/install -j$(nproc) BUILD_LOG=1
 
+      - name: Move logs to GITHUB_WORKSPACE
+        if: failure()
+        run: |
+          cp -r "$WORKPATH/logs" "$GITHUB_WORKSPACE"
+
       - name: Upload logs
         if: failure()
         uses: actions/upload-artifact at v2
         with:
           name: ${{ matrix.os }}-logs
-          path: "$WORKPATH/logs"
+          path: "logs"




More information about the lede-commits mailing list