How can I prevent the xdg-open popup in Puppeteer on Node.js (Alpine Linux)?

Using Puppeteer in a node:18-alpine container, I see an xdg-open popup from Chromium. Uninstalling utilities and modifying flags did not help. How can I disable this?

hey, i found that starting chromium in full headless mode with proper flags (–no-gpu --disable-setuid-sandbox) helps. sometimes you havent removed all gui-related bits though, check your container for any remaining xdg parts. might not be perfect but worked for me.

In my experience, after verifying that all unnecessary browser GUI packages have been removed, creating a no-op script for xdg-open resolved the popup issue. I simply replaced xdg-open with a script that exits successfully, so any calls to it did nothing. Additionally, including extra flags like --disable-extensions and --no-first-run helped to ensure that Chromium did not attempt any auto-start behaviors. This approach proved stable in my Alpine environment, ensuring a clean headless operation without unwanted popups.