Open Dhermann27 opened 2 months ago
If you are using laravel sail, you can simply add selenium service to your docker-compose
file (https://laravel.com/docs/10.x/sail#laravel-dusk) and use custom selenium client
$client = Client::createSeleniumClient('selenium:4444/wd/hub');
I've been fighting all day with this and hope someone in the community can explain why this is such a huge hassle.
The official Laravel Sail dockerfile is built from Ubuntu, which I gather does not have an associated chromium and chromedriver available. I have tried including the command in the apt-get install, downloading a stable release from the Debian site (to get around the necessity of snap), and including Linux64 binaries directly. Docker has a variety of responses to my futile attempts, but the most common are "No release candidate available", "please install snap beforehand", and a rosetta error "failed to open elf at /lib64/ld-linux-x86-64.so.2" which I think indicates that I have a mismatch in the binary's architecture.
If you have any ideas for how to easily add the necessary chromedriver and chrome/chromium dependencies to get Panther to work, I'm open to any option at this point.
Dockerfile (copied from Laravel Sail official 8.3 runtime)
docker-compose.yml
start-container
supervisord.conf