6
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

GitHub Actionsでダウンロードに失敗するときには HTTP HEADER に GitHub TokenでBearer認証をかける

Last updated at Posted at 2023-08-21

GitHub Actionsで,たとえばEXLAのように大きなファイルをダウンロードするような
Hexライブラリを利用する場合に,GitHub ActionsによるCIでダウンロードに
失敗することがあります.本記事は,そのような場合に有効な方法を示します.
Jonatan Kłosko さんが教えてくれました.

方法 (EXLAの場合)

次のようにして,環境変数 XLA_HTTP_HEADERS に GitHub Token で Bearer 認証をかけます.

env:
  XLA_HTTP_HEADERS: "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}"

一般解

HTTPでダウンロードするときに,HTTP HEADERに Authorization: Bearer ${{ secrets.GITHUB_TOKEN }} を渡します.

適用例

6
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
6
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?