Detect self-hosted runners not matching a GitHub-hosted runner image

* And give instructions for that case.
* Get the OS and OS version ourselves since some users set ImageOS incorrectly.
* This partially reverts commit ad1ebae995.
This commit is contained in:
Benoit Daloze
2023-03-03 16:33:57 +01:00
parent 2789f85824
commit 66dc012cc3
9 changed files with 440 additions and 140 deletions
+1 -1
View File
@@ -235,7 +235,7 @@ async function computeBaseKey(platform, engine, version, lockFile, cacheVersion)
const cwd = process.cwd()
const bundleWith = process.env['BUNDLE_WITH'] || ''
const bundleWithout = process.env['BUNDLE_WITHOUT'] || ''
let key = `setup-ruby-bundler-cache-v5-${platform}-${engine}-${version}-wd-${cwd}-with-${bundleWith}-without-${bundleWithout}`
let key = `setup-ruby-bundler-cache-v5-${common.getOSNameVersionArch()}-${engine}-${version}-wd-${cwd}-with-${bundleWith}-without-${bundleWithout}`
if (cacheVersion !== DEFAULT_CACHE_VERSION) {
key += `-v-${cacheVersion}`