aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristian Marangi <ansuelsmth@gmail.com>2023-05-25 02:44:21 +0200
committerChristian Marangi <ansuelsmth@gmail.com>2023-05-25 23:49:33 +0200
commitec6bbc52557e559a469761d182d690af20bf6189 (patch)
treefb2092813efdf7604341ef24d819e78ac34e3c0d
parent962334bc82bf358d56d52dd4d87be8d07db94543 (diff)
downloadupstream-ec6bbc52557e559a469761d182d690af20bf6189.tar.gz
upstream-ec6bbc52557e559a469761d182d690af20bf6189.tar.bz2
upstream-ec6bbc52557e559a469761d182d690af20bf6189.zip
CI: build: fix parse toolchain step failing for git strict rules
Commit 1cb8cdb ("ci: use new buildbot worker images with Debian 11") introduced new Git version with strict rules for owner of the git directory. To handle this and not cause major change, just move the parsing before the change of ownership of the openwrt directory permitting the correct run of git fetch command with the same user that did the repository checkout. Fixes: 1cb8cdb ("ci: use new buildbot worker images with Debian 11") Signed-off-by: Christian Marangi <ansuelsmth@gmail.com> (cherry picked from commit 0063e71d66766818fba286efe2a0ed8746c265e5)
-rw-r--r--.github/workflows/build.yml44
1 files changed, 22 insertions, 22 deletions
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 52fba8e106..816ef6ab3c 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -156,28 +156,6 @@ jobs:
repository: openwrt/telephony
path: openwrt/feeds/telephony
- - name: Fix permission
- run: |
- chown -R buildbot:buildbot openwrt
-
- - name: Prepare prebuilt tools
- shell: su buildbot -c "sh -e {0}"
- working-directory: openwrt
- run: |
- mkdir -p staging_dir build_dir
- ln -s /prebuilt_tools/staging_dir/host staging_dir/host
- ln -s /prebuilt_tools/build_dir/host build_dir/host
-
- ./scripts/ext-tools.sh --refresh
-
- - name: Update & Install feeds
- if: inputs.include_feeds == true
- shell: su buildbot -c "sh -e {0}"
- working-directory: openwrt
- run: |
- ./scripts/feeds update -a
- ./scripts/feeds install -a
-
- name: Parse toolchain file
if: inputs.build_toolchain == false
id: parse-toolchain
@@ -227,6 +205,28 @@ jobs:
echo "TOOLCHAIN_FILE=$TOOLCHAIN_FILE" >> "$GITHUB_ENV"
echo "TOOLCHAIN_PATH=$TOOLCHAIN_PATH" >> "$GITHUB_ENV"
+ - name: Fix permission
+ run: |
+ chown -R buildbot:buildbot openwrt
+
+ - name: Prepare prebuilt tools
+ shell: su buildbot -c "sh -e {0}"
+ working-directory: openwrt
+ run: |
+ mkdir -p staging_dir build_dir
+ ln -s /prebuilt_tools/staging_dir/host staging_dir/host
+ ln -s /prebuilt_tools/build_dir/host build_dir/host
+
+ ./scripts/ext-tools.sh --refresh
+
+ - name: Update & Install feeds
+ if: inputs.include_feeds == true
+ shell: su buildbot -c "sh -e {0}"
+ working-directory: openwrt
+ run: |
+ ./scripts/feeds update -a
+ ./scripts/feeds install -a
+
- name: Cache ccache
uses: actions/cache@v3
with: