I'm trying to automate some features with php-chrome
library.
I need to use chromium.chromedriver
installed on my server.
So I installed these apps.
root@afs2:~#: google-chrome --version
Google Chrome 116.0.5845.140
and
root@afs2:~# chromedriver --version
ChromeDriver 116.0.5845.96 (1a391816688002153ef791ffe60d9e899a71a037-refs/branch-heads/5845@{#1382})
But when I try to use chromedriver, I have this errors:
Fatal error: Uncaught RuntimeException: Chrome process stopped before startup completed. Additional info: cmd_run.go:1046: WARNING: cannot create user data directory: cannot update the 'current' symlink of "/var/www/snap/chromium/current": remove /var/www/snap/chromium/current: permission denied Sorry, home directories outside of /home needs configuration. See https://forum.snapcraft.io/t/11209 for details. in /var/www/afsv.com/vendor/chrome-php/chrome/src/Browser/BrowserProcess.php:410 Stack trace: #0 /var/www/afsv.com/vendor/chrome-php/chrome/src/Utils.php(60): HeadlessChromium\Browser\BrowserProcess->HeadlessChromium\Browser{closure}() #1 /var/www/afsv.com/vendor/chrome-php/chrome/src/Browser/BrowserProcess.php(450): HeadlessChromium\Utils::tryWithTimeout() #2 /var/www/afsv.com/vendor/chrome-php/chrome/src/Browser/BrowserProcess.php(139): HeadlessChromium\Browser\BrowserProcess->waitForStartup() #3 /var/www/afsv.com/vendor/chrome-php/chrome/src/BrowserFactory.php(81): HeadlessChromium\Browser\BrowserProcess->start() #4 /va in /var/www/afsv.com/vendor/chrome-php/chrome/src/Browser/BrowserProcess.php on line 410
Does anyone know how can I fix this?
Thanks in advance