Skip to content

Permission denied when creating symlinks on macOS self-hosted runners #1301

@AttilaT

Description

@AttilaT

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: actions/python-versions#384

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions