question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Building on self-hosted Windows 10: Failed to run "sh "

See original GitHub issue

Hey!

Bug description I am trying to set up a build pipeline, and since we have a lot of spare Windows 10 workstations around, I felt it would be a good use for them to be part of a build farm.

Unfortunately, it seems that there is a problem, please review the information below:

OS: Windows 10 64bit

Configuration

- uses: game-ci/unity-builder@v2
  env:
    UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }}
    UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }}
    UNITY_SERIAL: ${{ secrets.UNITY_SERIAL }}
  with:
    unityVersion: '2019.2.17f1'
    targetPlatform: StandaloneWindows       

Error Log

##[debug]Evaluating: secrets.UNITY_EMAIL
##[debug]Evaluating Index:
##[debug]..Evaluating secrets:
##[debug]..=> Object
##[debug]..Evaluating String:
##[debug]..=> 'UNITY_EMAIL'
##[debug]=> '***'
##[debug]Result: '***'
##[debug]Evaluating: secrets.UNITY_PASSWORD
##[debug]Evaluating Index:
##[debug]..Evaluating secrets:
##[debug]..=> Object
##[debug]..Evaluating String:
##[debug]..=> 'UNITY_PASSWORD'
##[debug]=> '***'
##[debug]Result: '***'
##[debug]Evaluating: secrets.UNITY_SERIAL
##[debug]Evaluating Index:
##[debug]..Evaluating secrets:
##[debug]..=> Object
##[debug]..Evaluating String:
##[debug]..=> 'UNITY_SERIAL'
##[debug]=> '***'
##[debug]Result: '***'
##[debug]Evaluating condition for step: 'Run game-ci/unity-builder@v2'
##[debug]Evaluating: success()
##[debug]Evaluating success:
##[debug]=> true
##[debug]Result: true
##[debug]Starting: Run game-ci/unity-builder@v2
##[debug]Loading inputs
##[debug]Loading env
Run game-ci/unity-builder@v2
  with:
    unityVersion: 2019.2.17f1
    targetPlatform: StandaloneWindows
    versioning: Semantic
    androidAppBundle: false
    awsBaseStackName: game-ci
    cloudRunnerCluster: local
    cloudRunnerCpu: 1.0
    cloudRunnerMemory: 750M
    kubeVolumeSize: 5Gi
  env:
    UNITY_EMAIL: ***
    UNITY_PASSWORD: ***
    UNITY_SERIAL: ***
Warning: 
      Library folder does not exist.
      Consider setting up caching to speed up your workflow,
      if this is not your first build.
    
##[debug]exec tool: C:\Program Files\Git\cmd\git.exearguments:   rev-parse   --is-shallow-repositoryExit code 0 received from tool 'C:\Program Files\Git\cmd\git.exe'STDIO streams have closed for tool 'C:\Program Files\Git\cmd\git.exe'
true

##[debug]exec tool: C:\Program Files\Git\cmd\git.exearguments:   fetch   --unshallowExit code 0 received from tool 'C:\Program Files\Git\cmd\git.exe'STDIO streams have closed for tool 'C:\Program Files\Git\cmd\git.exe'

Error: Failed to run "sh ".
 In-command error caught: Error: Unable to locate executable file: sh. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also verify the file has a valid extension for an executable file.
##[debug]Node Action run completed with exit code 1
##[debug]Finishing: Run game-ci/unity-builder@v2```

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

3reactions
deitrycommented, Jun 27, 2022

It seems there is still a call to sh somewhere. Adding C:\Program Files\Git\bin to PATH surely helps

Read more comments on GitHub >

github_iconTop Results From Across the Web

Unable to run bash scripts on a windows installed runner #1328
I have the same behavior on my self-hosted windows runner. Execute the following action. - run: ls shell: bash. gives the following error....
Read more >
Azure Pipeline: Bash script fails to run when running a self ...
I would like to run a self hosted agent on Windows 10 to build a project in a pipeline using a local compiler....
Read more >
Self-hosted pipeline agents fail to run as a service if SELinux ...
This seems to be a discussion in a few bug reports, so mentioning this explicitly. `config.sh` runs fine and configures everything. The agent...
Read more >
Troubleshoot self-hosted runner - CircleCI
In the UI the error will be in a Runner Instance Failure step with a message resembling: could not start task containers: error...
Read more >
Run the agent with a self-signed certificate - Azure Pipelines
This error may indicate the server certificate you used on your TFS server is not trusted by the build machine. Make sure you...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found