From 1f7391981db01555027d046e828ff070c34fe119 Mon Sep 17 00:00:00 2001 From: Paulo Lieuthier Date: Thu, 21 Sep 2023 07:41:06 -0300 Subject: [PATCH] pkr: created writable hostedtoolcache directory expected by ruby/setup-ruby --- pkr/runner.pkr.hcl | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pkr/runner.pkr.hcl b/pkr/runner.pkr.hcl index a9ad81c..4fc1446 100644 --- a/pkr/runner.pkr.hcl +++ b/pkr/runner.pkr.hcl @@ -38,6 +38,11 @@ build { "sudo ln -s /usr/local/bin/gsed /usr/local/bin/sed", "sudo git config --system credential.helper ''", + # ruby/setup-ruby expects writable /Users/runner/hostedtoolcache + "sudo mkdir -p /Users/runner/hostedtoolcache", + "sudo ln -s /Users/runner/hostedtoolcache /Users/vagrant/hostedtoolcache", + "sudo chown vagrant /Users/vagrant/hostedtoolcache /Users/runner/hostedtoolcache", + # don't install through brew because of installation errors # "brew install --cask intel-haxm", "curl -sSLfo haxm.zip https://github.com/intel/haxm/releases/download/v7.8.0/haxm-macosx_v7_8_0.zip",