Running an action via svc start doesn't update runners environment variables - causing failures on jobs
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 6.3k
- Forks
- 1.4k
- Avg merge
- 1d 16h
- Merged PRs (30d)
- 24
Description
How to reproduce:
method 1:
- install and run self-hosted runner on a mac build machine (i.e.
./svc.sh installand ./svc.sh start`) - Add some new items to your
$PATHvariable - restart your runner so changes take effect with
./svc.sh stopand./svc.sh start - Run your job that requires the new PATH dependencies
Expected behaviour:
New variables added to path can now be accessed via the Action
Actual behaviour:
You'll get the same error as the path was not updated for some reason. But if you activate the runner via run.sh then the changes will take effect.
I've worked around this by manually editing the .paths file in actions-runner. But I recently tried the same with my homebrew installation and it isn't working even after updating the path. Is there a saved version of the .zshrc file within the actions-runner folder or something?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the macOS service path using svc.sh install, svc.sh start, and svc.sh stop, then compare it with run.sh. Review how the runner uses the .paths file and whether .zshrc is involved. Done means newly added PATH entries are available to jobs after restarting the service, as they are when using run.sh.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp, macos, zsh
- Domain
- ci-cd, devops, operating-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100