mirror of
https://github.com/centreon/centreon-plugins.git
synced 2025-07-31 01:24:35 +02:00
test(ci): test token usage for delivery action
This commit is contained in:
parent
c00b0040c6
commit
c708e45928
9
.github/actions/package-delivery/action.yml
vendored
9
.github/actions/package-delivery/action.yml
vendored
@ -29,11 +29,11 @@ runs:
|
||||
- name: Check workflow statuses and display token usage
|
||||
run: |
|
||||
echo "github token rate usage:"
|
||||
curl -s -H "Accept: application/vnd.github+json" -H "Authorization: token ${{ github.token }}" https://api.github.com/rate_limit
|
||||
curl -s -H "Accept: application/vnd.github+json" -H "Authorization: token ${{ github.token }}" https://api.github.com/rate_limit | jq .core
|
||||
echo ""
|
||||
echo ""
|
||||
echo "anonymous rate usage:"
|
||||
curl -s -H "Accept: application/vnd.github+json" https://api.github.com/rate_limit
|
||||
curl -s -H "Accept: application/vnd.github+json" https://api.github.com/rate_limit | jq .core
|
||||
echo ""
|
||||
echo ""
|
||||
shell: bash
|
||||
@ -41,6 +41,7 @@ runs:
|
||||
- name: Download packages from testing
|
||||
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
|
||||
with:
|
||||
github-token: ${{ github.token }}
|
||||
script: |
|
||||
const warningNoPromote = 'No packages are promoted because push is not related to a hotfix/release pull request.';
|
||||
const commitSha = context.sha;
|
||||
@ -52,11 +53,11 @@ runs:
|
||||
- name: Check workflow statuses and display token usage
|
||||
run: |
|
||||
echo "github token rate usage:"
|
||||
curl -s -H "Accept: application/vnd.github+json" -H "Authorization: token ${{ github.token }}" https://api.github.com/rate_limit
|
||||
curl -s -H "Accept: application/vnd.github+json" -H "Authorization: token ${{ github.token }}" https://api.github.com/rate_limit | jq .core
|
||||
echo ""
|
||||
echo ""
|
||||
echo "anonymous rate usage:"
|
||||
curl -s -H "Accept: application/vnd.github+json" https://api.github.com/rate_limit
|
||||
curl -s -H "Accept: application/vnd.github+json" https://api.github.com/rate_limit | jq .core
|
||||
echo ""
|
||||
echo ""
|
||||
shell: bash
|
||||
|
Loading…
x
Reference in New Issue
Block a user