actions / actions/setup-python

Permission denied when creating symlinks on macOS self-hosted runners

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

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

feature request
主要言語
TypeScript
スター
2.2k
フォーク
739
平均マージ
6日 18時間
マージ済み PR(30日)
1

説明

Description:

Problem

setup-python fails on self-hosted macOS EC2 runners with:

Error: ln: python314: Permission denied

The setup.sh installer script uses sudo to install the Python framework into /Library/Frameworks/ (line 50), but the subsequent symlink creation inside that root-owned directory runs without sudo, causing a permission error on runners where the CI user is not an admin.

Action version:
v6

Platform:

  • Ubuntu
  • macOS
  • Windows

Runner type:

  • Hosted
  • Self-hosted

Tools version:

Any

Repro steps:
Make a deployment on a MacOS instance where the runner is running as a standard user with sudo permission.

Expected behavior:
The installation process creates symbolic links without failures.

Actual behavior:
Image

Fix:
Can be addressed by this PR: https://github.com/actions/python-versions/pull/384

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

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

調査の方向性

setup.sh の50行目付近と、actions/python-versions#384 で参照されている pull request を確認し、インストーラーとシンボリックリンクの手順を理解します。標準ユーザーの macOS self-hosted runner で setup-python v6 のインストールを再現し、その後、シンボリックリンクの作成が権限エラーなしで完了することを確認します。

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

評価

技術スタック
github-actions, python, shell
領域
ci-cd
issue の種類
バグ
難易度
2/5
見積もり時間
1〜3時間
活発さ
停滞
明瞭さ
明確に書かれている
初心者へのやさしさ
35/100

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

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