Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions .github/ACTIONS_LOCKFILE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# GitHub Actions dependency lockfile

Existing workflows and the lockfile verification workflow are covered by
`.github/workflows/actions.lock`. The lockfile records exact commits and
source repository identities, including transitive action dependencies.

After adding a workflow or changing an action reference, regenerate with:

```sh
gh extension install github/gh-actions-lock --pin v0.4.0
gh actions-lock --no-narrow
gh actions-lock --verify
```

Review changed commits and repository identities before committing the
workflows and lockfile together. Existing action version references are kept
as written. GitHub Actions Dependabot updates run weekly as one group and
maintain lockfile entries for onboarded workflows.

A moved branch or major tag does not automatically update the locked commit.
Review the upstream change, then use `gh actions-lock --relock --no-narrow`.
Do not use `--accept-moved` in automation or edit the lockfile by hand.

This covers action code, not service/container images, runner images,
packages installed by scripts, or external reusable workflow calls. The latter
require explicit SHA pins and a lockfile in their source repository.
Local `./` actions use the checked-out workspace and are not locked.

The verification job checks consistency and provenance with read-only
repository permissions. It does not prove the locked actions are safe and
does not execute application tests or deployment scripts.

Docs: https://docs.github.com/en/actions/concepts/security/workflow-dependency-lockfiles
9 changes: 9 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
groups:
github-actions:
patterns: ["*"]
50 changes: 50 additions & 0 deletions .github/workflows/actions.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# This file is machine-generated by `gh actions-lock`.
# Do not edit by hand; run `gh actions-lock` to update.
# Docs: https://gh.io/actions-lockfile
version: 'v0.0.3'
workflows:
'.github/workflows/publish-docker-image.yml':
- 'actions/checkout@v3'
- 'docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc'
- 'docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9'
- 'docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38'
- 'docker/setup-buildx-action@v1'
- 'docker/setup-qemu-action@v1'
'.github/workflows/verify-actions-lockfile.yml':
- 'actions/checkout@v7.0.1'
dependencies:
'actions/checkout@v3':
ref: 'v3'
commit: 'sha1-a37ce9120846195fa4ece8f58b268e6043cb2f26'
owner_id: 44036562
repo_id: 197814629
'actions/checkout@v7.0.1':
ref: 'v7.0.1'
commit: 'sha1-3d3c42e5aac5ba805825da76410c181273ba90b1'
owner_id: 44036562
repo_id: 197814629
'docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc':
ref: 'v2.5.0'
commit: 'sha1-ad44023a93711e3deb337508980b4b5e9bcdc5dc'
owner_id: 5429470
repo_id: 241092383
'docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9':
ref: 'v1.10.0'
commit: 'sha1-f054a8b539a109f9f41c372932f1ae047eff08c9'
owner_id: 5429470
repo_id: 287743349
'docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38':
ref: 'v3.3.0'
commit: 'sha1-98669ae865ea3cffbcbaa878cf57c20bbf1c6c38'
owner_id: 5429470
repo_id: 306769011
'docker/setup-buildx-action@v1':
ref: 'v1'
commit: 'sha1-f211e3e9ded2d9377c8cadc4489a4e38014bc4c9'
owner_id: 5429470
repo_id: 288485773
'docker/setup-qemu-action@v1':
ref: 'v1'
commit: 'sha1-27d0a4f181a40b142cce983c5393082c365d1480'
owner_id: 5429470
repo_id: 288487894
27 changes: 27 additions & 0 deletions .github/workflows/verify-actions-lockfile.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Verify Actions lockfile

on:
pull_request:
push:
branches: [main]
workflow_dispatch:

permissions:
contents: read

jobs:
verify:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v7.0.1
with:
persist-credentials: false
- name: Install pinned lockfile verifier
run: gh extension install github/gh-actions-lock --pin v0.4.0
env:
GH_TOKEN: ${{ github.token }}
- name: Verify locked dependencies
run: gh actions-lock --verify
env:
GH_TOKEN: ${{ github.token }}
Loading