Failed to Launch Browser Process and Permissions Problem #768
anuzpandey
started this conversation in
General
Replies: 2 comments 1 reply
-
Hello, pls, you see next link click |
Beta Was this translation helpful? Give feedback.
0 replies
-
Did you resolve this issue? I have exact the same app, but running supervisor as a specific user and supervisor throws npm not found and node not found, however when I run queue:work as this user it works. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Description:
I'm encountering an issue with the Browsershot package in my Laravel application while generating PDFs in a queue worker using Supervisor. The application works fine in my local environment but throws an error in my production setup on Ubuntu 22. I have tried various solutions, but I'm unable to resolve the issue.
Problem 1: Failed to Launch Browser Process:
When the queue worker tries to use Browsershot, it throws the following error:
Error: Failed to launch the browser process! cmd_run.go:1046: WARNING: cannot create user data directory: cannot create snap home dir: mkdir /var/www/snap: permission denied /system.slice/supervisor.service is not a snap cgroup
Problem 2: Permissions Issue:
After changing the user in Supervisor's configuration to www-data, I started encountering permission-related issues. For instance, Browsershot requires the www-data user to create directories and files for generating PDFs, but I'm unsure about the correct way to grant these permissions without compromising security.
What I've Tried:
Environment:
Supervisor Config:
Question:
I would greatly appreciate any guidance or insights into resolving these issues. Thank you in advance for your help!
Beta Was this translation helpful? Give feedback.
All reactions