codesandbox / codesandbox/codesandbox-client

Executable bit is lost when forking

Open
#6,500 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
13.6k
Forks
2.4k
Avg merge
6d 19h
Merged PRs (30d)
2

Description

🐛 bug report

Description of the problem

Executable bit is lost after forking a sandbox.
Screenshot from 2022-02-28 20-04-25

How has this issue affected you? What are you trying to accomplish?

I forked a sandbox with production shell scripts triggered by a Dockerfile built container. To my surprise, the executeable bit was lost, which can be quite difficult to track down as the errors from k8s deployments, past the CI stage, are sometimes hard to reach.

To Reproduce
  1. Run touch start.sh && chmod a+x start.sh
  2. Fork the sandbox

Example sandbox with deploy.sh marked executeable https://codesandbox.io/s/mask-bug-25v8ms?file=/broken_file-cant_save.sh

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 with the reproduction steps and the linked example sandbox, then trace the sandbox forking flow to find where file permissions are copied. Done means an executable file such as start.sh or deploy.sh retains its executable bit after a fork, including in the Dockerfile-based workflow.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, javascript, shell
Domain
devtools
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.