actions / actions/checkout

Permission error when repository content shall be written to disk

Open
#587 2 comments 10 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
8.9k
Forks
2.8k
PR merge metrics
No merged PRs in 30d

Description

I’m trying to use an image from Docker Hub, makarius/isabelle, for automated builds. However, if usage of this image is enabled, checking out my repository fails with the error EACCES: permission denied, open '/__w/⟨repository-name⟩/⟨repository-name⟩/⟨uuid⟩.tar.gz'. The repository is downloaded using the GitHub REST API.

A minimal workflow file that triggers this error is as follows:

name: Automated checkout

on: [push]

jobs:
  checkout:
    runs-on: ubuntu-latest
    container: makarius/isabelle
    steps:
      - name: Check out repository
        uses: actions/checkout@v2

Unfortunately, the above error message, while mentioning a path, does not tell, on which machine the respective directories should exist and what permissions they should have.

From the documentation, I cannot tell, what actions/checkout@v2 is trying to achieve. Does the virtual host try to write the data into the container and doesn’t have write permissions? Or does the container try to copy the data from the virtual host onto its own disk, and, if yes, is the problem that it cannot read the data or that it cannot write the data?

Are there any constraints a docker image to be used with actions/checkout@v2 has to fulfill? If yes, where are these documented?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the minimal workflow with actions/checkout@v2 and the makarius/isabelle container, then trace where the GitHub REST API download is written. Check the checkout action's container assumptions and permission handling. Done means the permission cause and required container constraints are identified and either documented or corrected.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, github-actions, typescript
Domain
ci-cd, devops
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.