feat!: use ~/.cache/puppeteer for browser downloads (#9095)

This commit is contained in:
jrandolf
2022-10-11 13:20:45 +02:00
committed by GitHub
parent 557d4a06c4
commit 3df375baed
28 changed files with 47 additions and 232 deletions

View File

@@ -141,7 +141,7 @@ jobs:
- name: Setup cache for Chromium binary
uses: actions/cache@v3
with:
path: packages/puppeteer-core/.local-chromium
path: ~/.cache/puppeteer/chrome
key: ${{ runner.os }}-chromium-${{ hashFiles('packages/puppeteer-core/src/revisions.ts') }}
- name: Install Chromium
run: npm run postinstall
@@ -184,7 +184,7 @@ jobs:
- name: Setup cache for Firefox binary
uses: actions/cache@v3
with:
path: packages/puppeteer-core/.local-firefox
path: ~/.cache/puppeteer/firefox
key: ${{ runner.os }}-firefox-${{ hashFiles('packages/puppeteer-core/src/revisions.ts') }}
- name: Install Firefox
env:

View File

@@ -38,7 +38,7 @@ jobs:
# Ensure both a Chromium and a Firefox binary are available.
PUPPETEER_PRODUCT=firefox npm install
npm install
ls .local-chromium .local-firefox
ls ~/.cache/puppeteer
REV=$(node tools/check_availability.js -p linux)
echo "Installing revision $REV"
cat src/revisions.ts | sed "s/[0-9]\{6,\}/$REV/" > src/revisions.ts.replaced
@@ -76,7 +76,7 @@ jobs:
# Ensure both a Chromium and a Firefox binary are available.
PUPPETEER_PRODUCT=firefox npm install
npm install
ls .local-chromium .local-firefox
ls ~/.cache/puppeteer
REV=$(node tools/check_availability.js -p linux)
echo "Installing revision $REV"
cat src/revisions.ts | sed "s/[0-9]\{6,\}/$REV/" > src/revisions.ts.replaced
@@ -114,7 +114,7 @@ jobs:
# Ensure both a Chromium and a Firefox binary are available.
PUPPETEER_PRODUCT=firefox npm install
npm install
ls .local-chromium .local-firefox
ls ~/.cache/puppeteer
REV=$(node tools/check_availability.js -p linux)
echo "Installing revision $REV"
cat src/revisions.ts | sed "s/[0-9]\{6,\}/$REV/" > src/revisions.ts.replaced