Unlighthouse detects and uses your system Chrome to keep package size minimal. When unavailable, it downloads a compatible Chromium binary.
You can disable the system chrome usage by modifying the chrome.useSystem flag.
This will make Unlighthouse download and use the latest Chrome binary instead.
import { defineUnlighthouseConfig } from 'unlighthouse/config'
export default defineUnlighthouseConfig({
chrome: {
useSystem: false
},
})
When Chrome can't be found on your system or if the chrome.useSystem: false flag is passed, then a fallback will be attempted.
This fallback will download a chrome binary for your system and use that path.
There are a number of options you can customize on this.
chrome.useDownloadFallback - Disables the fallback installerchrome.downloadFallbackVersion - Which version of chromium to use (default 1095492)chrome.downloadFallbackCacheDir - Where the binary should be saved (default $home/.unlighthouse)export default defineUnlighthouseConfig({
chrome: {
useDownloadFallback: true,
downloadFallbackVersion: '1095492',
downloadFallbackCacheDir: '/tmp/unlighthouse',
},
})
You can provide your own chrome path by setting puppeteerOptions.executablePath.
export default defineUnlighthouseConfig({
puppeteerOptions: {
executablePath: '/usr/bin/chrome',
},
})