terraform-providers: add github token to update-providers
This commit is contained in:
parent
7ab926e57b
commit
9fde2b66f8
|
@ -25,6 +25,8 @@ jobs:
|
|||
run: |
|
||||
echo "title=terraform-providers: update $(date -u +"%Y-%m-%d")" >> $GITHUB_OUTPUT
|
||||
- name: update terraform-providers
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
run: |
|
||||
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
|
||||
git config user.name "github-actions[bot]"
|
||||
|
|
|
@ -137,7 +137,7 @@ repo="$(echo "${provider_source_url}" | cut -d '/' -f 5)"
|
|||
update_attr repo "${repo}"
|
||||
|
||||
if [[ ${spdx} == 1 ]]; then
|
||||
spdx="$(curl -L -s "https://api.github.com/repos/${org}/${repo}/license" | jq -r '.license.spdx_id')"
|
||||
spdx="$(curl -L -s ${GITHUB_TOKEN:+-u ":${GITHUB_TOKEN}"} "https://api.github.com/repos/${org}/${repo}/license" | jq -r '.license.spdx_id')"
|
||||
update_attr spdx "${spdx}"
|
||||
fi
|
||||
|
||||
|
|
Loading…
Reference in a new issue