У меня geckodriver
в той же директории, что и у Dockerfile.
Я попытался установить executable_path
для моего веб-драйвера на "./geckodriver"
, "geckodriver"
и "/app/geckodriver"
browser = webdriver.Firefox(options=options, executable_path="./geckodriver", firefox_profile=fp, capabilities=capabilities_argument)
Я получаю это сообщение об ошибке.
Could not find firefox in your system PATH. Please specify the binary location or install firefox
Мой Dockerfile выглядит следующим образом
# Use an official Python runtime as a parent image
FROM python:3.6
# Set buffered environment variable
ENV PYTHONUNBUFFERED 1
# Set the working directory to /app
RUN mkdir /app
WORKDIR /app
# Make port 80 available to the world outside this container
EXPOSE 80
# Install packacges needed for crontab and selenium
RUN apt-get update && apt-get install -y sudo libpulse0 pulseaudio software-properties-common libappindicator1 fonts-liberation xserver-xephyr
RUN apt-get install binutils libproj-dev gdal-bin cron nano -y
# Install any needed packages specified in requirements.txt
ADD requirements.txt /app/
RUN pip install -r requirements.txt
ADD . /app/
# Run script
CMD ["./scrape.sh"]