Skip to content

Commit 8a82ea2

Browse files
mishushakovclaude
andauthored
chore(ci): pin GitHub Actions to commit SHAs (#241)
Pin all 39 external action references across the workflow files to full 40-char commit SHAs, with the resolved semver as a trailing comment, so a retagged or hijacked upstream release can't silently change what CI runs. Two refs (pnpm/action-setup@v3, changesets/action@v1) were moving branch refs rather than tags; both matched their newest tags and are pinned there. Local reusable-workflow refs are left alone since they resolve within the repo at the triggering commit. Also add the helpers:pinGitHubActionDigests Renovate preset so digests stay pinned and keep getting update PRs instead of being reverted to tags. Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
1 parent 107f349 commit 8a82ea2

8 files changed

Lines changed: 45 additions & 40 deletions

File tree

‎.github/workflows/js-sdk-tests.yml‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,24 +19,24 @@ jobs:
1919
name: Build and test SDK
2020
steps:
2121
- name: Checkout repository
22-
uses: actions/checkout@v4
22+
uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.4.0
2323

2424
- name: Parse .tool-versions
25-
uses: wistia/parse-tool-versions@v2.1.1
25+
uses: wistia/parse-tool-versions@32f568a4ffd4bfa7720ebf93f171597d1ebc979a # v2.1.1
2626
id: tool-versions
2727
with:
2828
filename: '.tool-versions'
2929
uppercase: 'true'
3030
prefix: 'tool_version_'
3131

3232
- name: Install pnpm
33-
uses: pnpm/action-setup@v4
33+
uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 # v4.3.0
3434
id: pnpm-install
3535
with:
3636
version: ${{ env.TOOL_VERSION_PNPM }}
3737

3838
- name: Setup Node
39-
uses: actions/setup-node@v3
39+
uses: actions/setup-node@3235b876344d2a9aa001b8d1453c930bba69e610 # v3.9.1
4040
with:
4141
node-version: '${{ env.TOOL_VERSION_NODEJS }}'
4242
registry-url: 'https://registry.npmjs.org'

‎.github/workflows/lint.yml‎

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,22 +10,22 @@ jobs:
1010

1111
steps:
1212
- name: Checkout Repo
13-
uses: actions/checkout@v4
13+
uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.4.0
1414

1515
- name: Parse .tool-versions
16-
uses: wistia/parse-tool-versions@v2.1.1
16+
uses: wistia/parse-tool-versions@32f568a4ffd4bfa7720ebf93f171597d1ebc979a # v2.1.1
1717
id: tool-versions
1818
with:
1919
filename: '.tool-versions'
2020
uppercase: 'true'
2121
prefix: 'tool_version_'
2222

23-
- uses: pnpm/action-setup@v4
23+
- uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 # v4.3.0
2424
with:
2525
version: ${{ env.TOOL_VERSION_PNPM }}
2626

2727
- name: Setup Node.js
28-
uses: actions/setup-node@v4
28+
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
2929
with:
3030
node-version: '${{ env.TOOL_VERSION_NODEJS }}'
3131
cache: pnpm
@@ -39,12 +39,12 @@ jobs:
3939
run: pnpm install --frozen-lockfile
4040

4141
- name: Set up Python
42-
uses: actions/setup-python@v5
42+
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
4343
with:
4444
python-version: '${{ env.TOOL_VERSION_PYTHON }}'
4545

4646
- name: Install and configure Poetry
47-
uses: snok/install-poetry@v1
47+
uses: snok/install-poetry@a783c322200f0519c7926aa6faa857c4e23e9263 # v1.4.2
4848
with:
4949
version: ${{ env.TOOL_VERSION_POETRY }}
5050
virtualenvs-create: true

‎.github/workflows/publish_packages.yml‎

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -15,44 +15,44 @@ jobs:
1515
name: Publish Desktop SDK
1616
runs-on: ubuntu-22.04
1717
steps:
18-
- uses: actions/create-github-app-token@v1
18+
- uses: actions/create-github-app-token@d72941d797fd3113feb6b93fd0dec494b13a2547 # v1.12.0
1919
id: app-token
2020
with:
2121
app-id: ${{ vars.VERSION_BUMPER_APPID }}
2222
private-key: ${{ secrets.VERSION_BUMPER_SECRET }}
2323

2424
- name: Checkout Repo
25-
uses: actions/checkout@v3
25+
uses: actions/checkout@a37ce9120846195fa4ece8f58b268e6043cb2f26 # v3.7.0
2626
with:
2727
token: ${{ steps.app-token.outputs.token }}
2828

2929
- name: Parse .tool-versions
30-
uses: wistia/parse-tool-versions@v2.1.1
30+
uses: wistia/parse-tool-versions@32f568a4ffd4bfa7720ebf93f171597d1ebc979a # v2.1.1
3131
id: tool-versions
3232
with:
3333
filename: '.tool-versions'
3434
uppercase: 'true'
3535
prefix: 'tool_version_'
3636

3737
- name: Set up Python
38-
uses: actions/setup-python@v5
38+
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
3939
with:
4040
python-version: '${{ env.TOOL_VERSION_PYTHON }}'
4141

4242
- name: Install and configure Poetry
43-
uses: snok/install-poetry@v1
43+
uses: snok/install-poetry@a783c322200f0519c7926aa6faa857c4e23e9263 # v1.4.2
4444
with:
4545
version: ${{ env.TOOL_VERSION_POETRY }}
4646
virtualenvs-create: true
4747
virtualenvs-in-project: true
4848
installer-parallel: true
4949

50-
- uses: pnpm/action-setup@v4
50+
- uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 # v4.3.0
5151
with:
5252
version: ${{ env.TOOL_VERSION_PNPM }}
5353

5454
- name: Setup Node.js
55-
uses: actions/setup-node@v6
55+
uses: actions/setup-node@249970729cb0ef3589644e2896645e5dc5ba9c38 # v6.5.0
5656
with:
5757
node-version: '${{ env.TOOL_VERSION_NODEJS }}'
5858
registry-url: 'https://registry.npmjs.org'
@@ -77,7 +77,7 @@ jobs:
7777
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
7878

7979
- name: Release new versions
80-
uses: changesets/action@v1
80+
uses: changesets/action@a45c4d594aa4e2c509dc14a9f2b3b67ba3780d0d # v1.9.0
8181
with:
8282
publish: pnpm run publish
8383
createGithubReleases: true

‎.github/workflows/python-sdk-tests.yml‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,23 +19,23 @@ jobs:
1919
name: Build and test SDK
2020
steps:
2121
- name: Checkout repository
22-
uses: actions/checkout@v4
22+
uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.4.0
2323

2424
- name: Parse .tool-versions
25-
uses: wistia/parse-tool-versions@v2.1.1
25+
uses: wistia/parse-tool-versions@32f568a4ffd4bfa7720ebf93f171597d1ebc979a # v2.1.1
2626
id: tool-versions
2727
with:
2828
filename: '.tool-versions'
2929
uppercase: 'true'
3030
prefix: 'tool_version_'
3131

3232
- name: Set up Python
33-
uses: actions/setup-python@v5
33+
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
3434
with:
3535
python-version: '${{ env.TOOL_VERSION_PYTHON }}'
3636

3737
- name: Install and configure Poetry
38-
uses: snok/install-poetry@v1
38+
uses: snok/install-poetry@a783c322200f0519c7926aa6faa857c4e23e9263 # v1.4.2
3939
with:
4040
version: ${{ env.TOOL_VERSION_POETRY }}
4141
virtualenvs-create: true

‎.github/workflows/release.yml‎

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -19,24 +19,24 @@ jobs:
1919
release: ${{ steps.version.outputs.release }}
2020
steps:
2121
- name: Checkout Repo
22-
uses: actions/checkout@v3
22+
uses: actions/checkout@a37ce9120846195fa4ece8f58b268e6043cb2f26 # v3.7.0
2323

2424
- name: Parse .tool-versions
25-
uses: wistia/parse-tool-versions@v2.1.1
25+
uses: wistia/parse-tool-versions@32f568a4ffd4bfa7720ebf93f171597d1ebc979a # v2.1.1
2626
id: tool-versions
2727
with:
2828
filename: '.tool-versions'
2929
uppercase: 'true'
3030
prefix: 'tool_version_'
3131

3232
- name: Install pnpm
33-
uses: pnpm/action-setup@v4
33+
uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 # v4.3.0
3434
id: pnpm-install
3535
with:
3636
version: ${{ env.TOOL_VERSION_PNPM }}
3737

3838
- name: Setup Node
39-
uses: actions/setup-node@v6
39+
uses: actions/setup-node@249970729cb0ef3589644e2896645e5dc5ba9c38 # v6.5.0
4040
with:
4141
node-version: '${{ env.TOOL_VERSION_NODEJS }}'
4242
registry-url: "https://registry.npmjs.org"
@@ -67,24 +67,24 @@ jobs:
6767
python-sdk: ${{ steps.python.outputs.release }}
6868
steps:
6969
- name: Checkout Repo
70-
uses: actions/checkout@v3
70+
uses: actions/checkout@a37ce9120846195fa4ece8f58b268e6043cb2f26 # v3.7.0
7171

7272
- name: Parse .tool-versions
73-
uses: wistia/parse-tool-versions@v2.1.1
73+
uses: wistia/parse-tool-versions@32f568a4ffd4bfa7720ebf93f171597d1ebc979a # v2.1.1
7474
id: tool-versions
7575
with:
7676
filename: '.tool-versions'
7777
uppercase: 'true'
7878
prefix: 'tool_version_'
7979

8080
- name: Install pnpm
81-
uses: pnpm/action-setup@v4
81+
uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 # v4.3.0
8282
id: pnpm-install
8383
with:
8484
version: ${{ env.TOOL_VERSION_PNPM }}
8585

8686
- name: Setup Node
87-
uses: actions/setup-node@v6
87+
uses: actions/setup-node@249970729cb0ef3589644e2896645e5dc5ba9c38 # v6.5.0
8888
with:
8989
node-version: '${{ env.TOOL_VERSION_NODEJS }}'
9090
registry-url: 'https://registry.npmjs.org'
@@ -125,7 +125,7 @@ jobs:
125125
runs-on: ubuntu-latest
126126
steps:
127127
- name: Release Failed - Slack Notification
128-
uses: rtCamp/action-slack-notify@v2
128+
uses: rtCamp/action-slack-notify@33ca3be66c6f378fe1610fd1d5258632dbed5e58 # v2.4.0
129129
env:
130130
SLACK_COLOR: '#ff0000'
131131
SLACK_MESSAGE: ':here-we-go-again: :bob-the-destroyer: We need :fix-parrot: ASAP :pray:'

‎.github/workflows/template.yml‎

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,23 +21,23 @@ jobs:
2121
runs-on: ubuntu-22.04
2222
steps:
2323
- name: Checkout repository
24-
uses: actions/checkout@v3
24+
uses: actions/checkout@a37ce9120846195fa4ece8f58b268e6043cb2f26 # v3.7.0
2525

2626
- name: Parse .tool-versions
27-
uses: wistia/parse-tool-versions@v2.1.1
27+
uses: wistia/parse-tool-versions@32f568a4ffd4bfa7720ebf93f171597d1ebc979a # v2.1.1
2828
id: tool-versions
2929
with:
3030
filename: '.tool-versions'
3131
uppercase: 'true'
3232
prefix: 'tool_version_'
3333

3434
- name: Set up Python
35-
uses: actions/setup-python@v5
35+
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
3636
with:
3737
python-version: '${{ env.TOOL_VERSION_PYTHON }}'
3838

3939
- name: Install and configure Poetry
40-
uses: snok/install-poetry@v1
40+
uses: snok/install-poetry@a783c322200f0519c7926aa6faa857c4e23e9263 # v1.4.2
4141
with:
4242
version: ${{ env.TOOL_VERSION_POETRY }}
4343
virtualenvs-create: true
@@ -48,10 +48,10 @@ jobs:
4848
run: poetry install
4949

5050
- name: Set up Docker Buildx
51-
uses: docker/setup-buildx-action@v3
51+
uses: docker/setup-buildx-action@8d2750c68a42422c14e847fe6c8ac0403b4cbd6f # v3.12.0
5252

5353
- name: Log in to DockerHub
54-
uses: docker/login-action@v3
54+
uses: docker/login-action@c94ce9fb468520275223c153574b00df6fe4bcc9 # v3.7.0
5555
with:
5656
username: ${{ secrets.DOCKERHUB_USERNAME }}
5757
password: ${{ secrets.DOCKERHUB_TOKEN }}

‎.github/workflows/validate-renovate-config.yaml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
contents: read
1313
steps:
1414
- name: Checkout repository
15-
uses: actions/checkout@v6
15+
uses: actions/checkout@d23441a48e516b6c34aea4fa41551a30e30af803 # v6.1.0
1616

1717
- name: Validate Renovate config
18-
uses: suzuki-shunsuke/github-action-renovate-config-validator@v2.1.0
18+
uses: suzuki-shunsuke/github-action-renovate-config-validator@ee9f69e1f683ed0d08225086482b34fc9abe9300 # v2.1.0

‎renovate.json5‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,12 @@
22
// list of all presets: https://docs.renovatebot.com/presets-default/
33
{
44
$schema: 'https://docs.renovatebot.com/renovate-schema.json',
5-
extends: ['config:recommended', ':automergeRequireAllStatusChecks'],
5+
extends: [
6+
'config:recommended',
7+
':automergeRequireAllStatusChecks',
8+
// keep GitHub Actions pinned to commit SHAs (supply-chain hardening)
9+
'helpers:pinGitHubActionDigests',
10+
],
611
dependencyDashboard: true,
712
// let it fly for now, we've got a lot to catch up on
813
// schedule: [

0 commit comments

Comments
 (0)