Closed
Description
We run this action on a self-hosted ubuntu and mac machine. If the action is run dedicatedly, everything runs smoothly. However, we have several runners installed on the machine, so ruby/setup-ruby
action can be run in parallel. This leads to errors because they all access the same ruby version in /opt/hostedtoolcache/
Among others we got the following:
Run ruby/setup-ruby@v1
Error: Command failed: rm -rf "/Users/runner/hostedtoolcache/Ruby/3.0.1/x64"
rm: fts_read: No such file or directory
Installing Bundler
Using Bundler 2.2.20 from Gemfile.lock BUNDLED WITH 2.2.20
/opt/hostedtoolcache/Ruby/3.0.1/x64/bin/gem install bundler -v 2.2.20 --no-document
`/opt/hostedtoolcache/Ruby/3.0.1/x64/lib/ruby/gems/3.0.0/gems/bundler-2.2.20/exe/bundle` does not exist, maybe `gem pristine bundler` will fix it?
`/opt/hostedtoolcache/Ruby/3.0.1/x64/lib/ruby/gems/3.0.0/gems/bundler-2.2.20/exe/bundler` does not exist, maybe `gem pristine bundler` will fix it?
ERROR: While executing gem ... (Errno::ENOENT)
No such file or directory @ rb_sysopen - /opt/hostedtoolcache/Ruby/3.0.1/x64/lib/ruby/gems/3.0.0/specifications/bundler-2.2.20.gemspec
Took 0.75 seconds
Error: The process '/opt/hostedtoolcache/Ruby/3.0.1/x64/bin/gem' failed with exit code 1
Run ruby/setup-ruby@v1
Error: Command failed: rm -rf "/opt/hostedtoolcache/Ruby/3.0.1/x64"
rm: cannot remove '/opt/hostedtoolcache/Ruby/3.0.1/x64/lib/ruby/gems/3.0.0/gems/bundler-2.2.20/lib/bundler/man': Directory not empty
Other setup actions like node cache the version in the sub-folder _work/_tool
of the respective runner. What I got from the source code so far is that you can't change the path because of the pre-built ruby version. Since you are much more familiar with Ruby and this repository, I would be happy if you have a solution for this problem.
Metadata
Metadata
Assignees
Labels
No labels