Skip to content

Commit

Permalink
docs: update docs around gpu (#12052)
Browse files Browse the repository at this point in the history
  • Loading branch information
OrKoN committed Mar 7, 2024
1 parent c25388c commit 5174f2b
Showing 1 changed file with 20 additions and 7 deletions.
27 changes: 20 additions & 7 deletions docs/troubleshooting.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
# Troubleshooting

:::caution
:::note

Chromium currently does not provide arm64 binaries for Linux. There are only
binaries for Mac ARM.
To keep this page up-to-date we largely rely on community contributions.
Please send a PR if you notice something is no longer up-to-date.

:::
:::note

## `Cannot find module 'puppeteer-core/internal/...'`

Expand Down Expand Up @@ -78,6 +78,14 @@ common ones are provided below. Also, see
https://source.chromium.org/chromium/chromium/src/+/main:chrome/installer/linux/debian/dist_package_versions.json
for the up-to-date list of dependencies declared by the Chrome installer.

:::caution

Chrome currently does not provide arm64 binaries for Linux.
There are only arm64 binaries for Mac ARM.
That means that Linux binaries downloaded by default will not work on Linux arm64.

:::

<details>
<summary>Debian (e.g. Ubuntu) Dependencies</summary>

Expand Down Expand Up @@ -169,18 +177,23 @@ yum update nss -y

</details>

## Chrome headless disables GPU compositing
## chrome-headless-shell disables GPU compositing

Chrome/Chromium requires `--enable-gpu` to
chrome-headless-shell requires `--enable-gpu` to
[enable GPU acceleration in headless mode](https://crbug.com/1416283).

```ts
const browser = await puppeteer.launch({
headless: true,
headless: 'shell',
args: ['--enable-gpu'],
});
```

## Setting up GPU with Chrome

Generally, Chrome should be able to detect and enable GPU if the system has appropriate drivers.
For additional tips, see the following blog post https://developer.chrome.com/blog/supercharge-web-ai-testing.

## Setting Up Chrome Linux Sandbox

In order to protect the host environment from untrusted web content, Chrome uses
Expand Down

0 comments on commit 5174f2b

Please sign in to comment.