From d06c5324108c7217639d0dd4099f0e439bbf6267 Mon Sep 17 00:00:00 2001 From: Martine Lenders Date: Tue, 20 Apr 2021 11:03:47 +0200 Subject: [PATCH] gh-actions: release-tests: properly configure GH token for sudo --- .github/workflows/release-test.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release-test.yml b/.github/workflows/release-test.yml index 8f339914e9..14f5d288a2 100644 --- a/.github/workflows/release-test.yml +++ b/.github/workflows/release-test.yml @@ -54,7 +54,11 @@ jobs: steps: - name: Generate .riotgithubtoken run: | - echo '${{ secrets.RIOT_CI_ACCESS_TOKEN }}' > ~/.riotgithubtoken + if [ -z "${{ matrix.sudo }}" ]; then + echo '${{ secrets.RIOT_CI_ACCESS_TOKEN }}' > ~/.riotgithubtoken + else + sudo sh -c "echo '${{ secrets.RIOT_CI_ACCESS_TOKEN }}' > ~/.riotgithubtoken" + fi - name: Setup IoT-LAB credentials if: ${{ matrix.pytest_mark == 'iotlab_creds' }} run: |