CI: pin GitHub Actions by commit SHA
維護者通常 1 天內回覆
還沒有人認領這個 Issue。
評估
- 難度
- 2/5
- 預估耗時
- 1-3 小時
- 新手友好度
- 78/100
- Issue 類型
- 重構
- 描述清晰度
- 描述清楚
- 活躍度
- 活躍
- 技術堆疊
- github-actions, yaml
- 領域
- ci-cd
研究方向
從 .github/workflows/ci.yml 開始,該檔案中有三行 uses: 固定在版本標籤上(actions/checkout、actions/setup-python、ilammy/msvc-dev-cmd)。在各自的上游儲存庫中查找每個標籤對應的 40 位提交 SHA,並按 uses: owner/action@<sha> # vX.Y.Z 的格式寫入。可選的 .github/dependabot.yml 以及授權和行尾檢查工作則是單獨的額外工作。當工作流程中的每個 action 引用都固定到 SHA,且 CI 執行仍然通過時,即完成。
由索引模型根據 Issue 內容生成。
描述
.github/workflows/ci.yml references its three actions by version tag (actions/[email protected], actions/[email protected], ilammy/[email protected]). A tag can be moved by whoever controls the action's repository; a commit SHA cannot.
The exposure is small (the workflow has contents: read, no secrets, and publishes nothing), but pinning by SHA is the usual hardening for a public repository that takes outside pull requests.
To do
- Replace each tag with the 40-character commit SHA of that release, with the tag in a trailing comment (
uses: actions/checkout@<sha> # v4.2.2). - Optionally add
.github/dependabot.ymlfor thegithub-actionsecosystem so updates stay easy. - Optionally a line in the licence-and-line-endings job that fails when a workflow uses an action that is not pinned by SHA.
- 主要語言
- C++
- 星號
- 12
- 分支
- 2
- 平均合併
- 3 小時 10 分鐘
- 30 天內合併 PR
- 171
環境準備
- 沒有 Dockerfile 或 Docker Compose 檔案
- 有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
phantoslayer21/wronggpu 的其他 Issue
-
難度 2/5 1-3 小時 新手友好度 88/100
phantoslayer21/wronggpu#275 ·
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 82/100
phantoslayer21/wronggpu#274 ·
維護者通常 1 天內回覆
-
bug
難度 2/5 1-3 小時 新手友好度 88/100
phantoslayer21/wronggpu#241 ·
維護者通常 1 天內回覆
-
bug build
難度 2/5 1-3 小時 新手友好度 74/100
phantoslayer21/wronggpu#234 ·
維護者通常 1 天內回覆
-
bug build
難度 2/5 1-3 小時 新手友好度 80/100
phantoslayer21/wronggpu#233 ·
維護者通常 1 天內回覆
查看 phantoslayer21/wronggpu 的全部 Issue
相似的 Issue
-
ai_p2
難度 2/5 1-3 小時 新手友好度 80/100
ClickHouse/ClickHouse#132519 ·
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 76/100
juce-framework/JUCE#1810 ·
-
難度 1/5 1 小時以內 新手友好度 82/100
petercorke/robotics-toolbox-python#952 ·
維護者通常 1 天內回覆
-
NatronRenderer: a Python error in the script (-t / project script) doesn't change the exit status未關閉func:engine type:bug
難度 2/5 1-3 小時 新手友好度 72/100
NatronGitHub/Natron#1276 ·
維護者通常 1 天內回覆
-
難度 1/5 1-3 小時 新手友好度 77/100
維護者通常 1 天內回覆