Skip to content

Commit

Permalink
Merge pull request #29 from alkrauss48/issue-28/fix/thumbnail-generation
Browse files Browse the repository at this point in the history
fix: update puppeteer arguments to fix thumbnail generation
  • Loading branch information
alkrauss48 authored Sep 1, 2024
2 parents 5faf622 + 70fca13 commit bad9542
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions app/Jobs/GenerateThumbnail.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,19 @@ public function handle(): void
->waitUntilNetworkIdle()
->windowSize(1200, 630)
->newHeadless()
->setOption('args', ['--disable-web-security'])
->setOption('args', [
'--disable-web-security',
'--disable-gpu',
'--disable-dev-shm-usage',
'--disable-setuid-sandbox',
'--no-first-run',
'--no-sandbox',
'--no-zygote',
'--deterministic-fetch',
'--disable-features=IsolateOrigins',
'--disable-site-isolation-trials',
])
->setScreenshotType('jpeg', 90)
->noSandbox()
->setOption('addStyleTag', json_encode([
'content' => '.slide-view { height: 100vh !important; } '
.'.browsershot-hide { display: none !important; }',
Expand Down

0 comments on commit bad9542

Please sign in to comment.