I'm trying to run a python script with Selenium inside docker. Since the script is in a docker container, I keep getting this error:
selenium.common.exceptions.WebDriverException: Message: 'chromedriver' executable needs to be in PATH.
The code works just fine, when I run it on my computer and use the PATH to the chromedriver file, however a docker container can't see the PATH as it is isolated. I would use a pre-made docker image, however I need other dependencies for my code to run such as smtplib, imapclient, and beautifulsoup to name a few.
Is there a command that will tell Selenium that the chromedriver is in the same folder as the script, or some other way to make it visible to docker?