Migrate the npm packages publication to trusted publishing

オープン
#3,654 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 2 日以内に返信

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
45/100
issue の種類
機能追加
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
github-actions, yaml
領域
ci-cd, release

調査の方向性

Start by locating the publish-npm-package action and the pre-release, release, manual-publish-npm, and ci workflows. Update publication to use GitHub Actions OIDC with id-token: write and the required npm CLI version, then verify dry runs and check how next versions are promoted to latest without a publish token. The issue also calls for configuring each npm package’s trusted publisher and removing the API token secrets after publication works.

索引モデルが issue の本文から書いたものです。

説明

CI/CD :factory:

Why

npm deprecates the granular access tokens with direct publish access that bypass 2FA, and publishing new versions directly with such a token will no longer be possible in January 2027, whereas our workflows publish the npm packages with an API token (see https://github.blog/changelog/2026-07-08-npm-install-time-security-and-gat-bypass2fa-deprecation/ and https://github.com/npm/cli/issues/8547#issuecomment-5918553542).

What

Migrate the publication of the npm packages to trusted publishing from GitHub Actions (OIDC), so that the publication no longer relies on long-lived npm tokens.

How

  • Configure the trusted publisher (repository and workflows) of each npm package on npmjs.com (with "Allow npm dist-tag" ticked) (@jpraynaud)
  • Update the publish-npm-package action to publish with OIDC (id-token: write permission, minimum npm CLI version) instead of the API token
  • Adapt the publication jobs of the pre-release, release, manual-publish-npm and ci (dry run) workflows
  • Check how the promotion of a next version to latest works without a publish token
  • Remove the npm API token secrets once the publication works (@jpraynaud)
Ressources
主要言語
Rust
スター
155
フォーク
52
平均マージ
2日 17時間
マージ済み PR(30日)
37

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

IntersectMBO/mithril のほかの issue

IntersectMBO/mithril の issue をすべて見る

似ている issue

Rust の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。