ResourceCount #17768
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: ResourceCount | |
| on: | |
| schedule: | |
| - cron: '3 */1 * * *' # every hour | |
| workflow_dispatch: | |
| permissions: | |
| id-token: write # aws-actions/[email protected] | |
| jobs: | |
| counter: | |
| if: vars.CI_ACCOUNT_ID != '' || github.event_name == 'workflow_dispatch' | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| region: [us-east-2, us-west-2, eu-west-1, eu-north-1, us-east-1] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 | |
| - name: configure aws credentials | |
| uses: aws-actions/configure-aws-credentials@00943011d9042930efac3dcd3a170e4273319bc8 # v5.1.0 | |
| with: | |
| role-to-assume: arn:aws:iam::${{ vars.CI_ACCOUNT_ID }}:role/${{ vars.CI_ROLE_NAME }} | |
| aws-region: ${{ matrix.region }} | |
| - uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0 | |
| with: | |
| go-version-file: test/hack/resource/go.mod | |
| check-latest: true | |
| cache-dependency-path: "test/hack/resource/go.sum" | |
| - run: go run main.go | |
| working-directory: ./test/hack/resource/count | |
| name: "Run resource count script" |