From 5a2671caa1d1bd54ae1f6b1fce0b9df3bc4e423b Mon Sep 17 00:00:00 2001 From: Derek Morgan <79756941+morethancertified@users.noreply.github.com> Date: Fri, 18 Oct 2024 17:28:28 +0000 Subject: [PATCH] testing key --- .github/workflows/infracost.yml | 27 +++------------------------ 1 file changed, 3 insertions(+), 24 deletions(-) diff --git a/.github/workflows/infracost.yml b/.github/workflows/infracost.yml index 5295444..550f165 100644 --- a/.github/workflows/infracost.yml +++ b/.github/workflows/infracost.yml @@ -10,11 +10,12 @@ jobs: if: github.event_name == 'pull_request' && (github.event.action == 'opened' || github.event.action == 'synchronize') runs-on: ubuntu-latest environment: production + permissions: contents: read pull-requests: write # Required to post comments + steps: - - name: Setup Infracost uses: infracost/actions/setup@v3 with: @@ -50,26 +51,4 @@ jobs: --repo=$GITHUB_REPOSITORY \ --github-token=${{ github.token }} \ --pull-request=${{ github.event.pull_request.number }} \ - --behavior=update - - # Run Infracost on default branch and update Infracost Cloud - infracost-default-branch-update: - name: Infracost Default Branch Update - if: github.event_name == 'push' && (github.ref_name == 'main' || github.ref_name == 'master') - runs-on: ubuntu-latest - steps: - - name: Setup Infracost - uses: infracost/actions/setup@v3 - with: - api-key: ${{ secrets.INFRACOST_API_KEY }} - - - name: Checkout main/master branch - uses: actions/checkout@v4 - - - name: Run Infracost on default branch and update Infracost Cloud - run: | - infracost breakdown --path=. \ - --format=json \ - --out-file=infracost.json - - infracost upload --path=infracost.json || echo "Always pass main branch runs even if there are policy failures" \ No newline at end of file + --behavior=update \ No newline at end of file