Skip to content

Commit

Permalink
fix: pin github workflow actions to commit hash (#393)
Browse files Browse the repository at this point in the history
  • Loading branch information
zhongliang02 authored Jan 9, 2025
1 parent 46b77e1 commit 594f0ba
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/chromatic.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,14 @@ jobs:
if: env.CHROMATIC_PROJECT_TOKEN != ''
- name: Load .env file
if: env.CHROMATIC_PROJECT_TOKEN != ''
uses: xom9ikk/dotenv@v2
# xom9ikk/dotenv@v2, using commit hash to pin as tags may be updated in supply chain attack
uses: xom9ikk/dotenv@eff1dce037c4c0143cc4180a810511024c2560c0
with:
mode: test
- name: Publish to Chromatic
if: env.CHROMATIC_PROJECT_TOKEN != ''
uses: chromaui/action@latest
# chromaui/action@latest, using commit hash to pin to silence codeQL
uses: chromaui/action@012a0241a4df3f0f831c99f02e2085c9641a25ba
with:
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
onlyChanged: true
Expand Down
9 changes: 6 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@ jobs:
DD_SERVICE_NAME: ${{ secrets.DD_SERVICE_NAME }}
DD_API_KEY: ${{ secrets.DD_API_KEY }}
if: env.DD_SERVICE_NAME != '' && env.DD_API_KEY != ''
uses: datadog/test-visibility-github-action@v2
# datadog/[email protected], using commit hash to pin to silence codeQL
uses: datadog/test-visibility-github-action@fd12a97414bee507eff1270d8ac3286313e3797e
with:
languages: js
service: ${{ secrets.DD_SERVICE_NAME }}
Expand All @@ -71,7 +72,8 @@ jobs:
- name: Install Playwright (Chromium)
run: npx playwright install chromium
- name: Load .env file
uses: xom9ikk/dotenv@v2
# xom9ikk/dotenv@v2, using commit hash to pin as tags may be updated in supply chain attack
uses: xom9ikk/dotenv@eff1dce037c4c0143cc4180a810511024c2560c0
with:
mode: test
- name: Next.js cache
Expand All @@ -98,7 +100,8 @@ jobs:
DD_SERVICE_NAME: ${{ secrets.DD_SERVICE_NAME }}
DD_API_KEY: ${{ secrets.DD_API_KEY }}
if: env.DD_SERVICE_NAME != '' && env.DD_API_KEY != ''
uses: datadog/test-visibility-github-action@v2
# datadog/[email protected], using commit hash to pin to silence codeQL
uses: datadog/test-visibility-github-action@fd12a97414bee507eff1270d8ac3286313e3797e
with:
languages: js
service: ${{ secrets.DD_SERVICE_NAME }}
Expand Down

1 comment on commit 594f0ba

@vercel
Copy link

@vercel vercel bot commented on 594f0ba Jan 9, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.