symfony-docker icon indicating copy to clipboard operation
symfony-docker copied to clipboard

symfony/panther issue, cannot install chrome driver

Open zmitic opened this issue 1 year ago • 4 comments

I created new repository and tried symfony/panther package. After running composer command from container, this was added to Dockerfile:

###> symfony/panther ###
# Chromium and ChromeDriver
ENV PANTHER_NO_SANDBOX 1
# Not mandatory, but recommended
ENV PANTHER_CHROME_ARGUMENTS='--disable-dev-shm-usage'
#RUN apk add --no-cache chromium chromium-chromedriver

# Firefox and geckodriver
#ARG GECKODRIVER_VERSION=0.29.0
#RUN apk add --no-cache firefox
#RUN wget -q https://github.com/mozilla/geckodriver/releases/download/v$GECKODRIVER_VERSION/geckodriver-v$GECKODRIVER_VERSION-linux64.tar.gz; \
#	tar -zxf geckodriver-v$GECKODRIVER_VERSION-linux64.tar.gz -C /usr/bin; \
#	rm geckodriver-v$GECKODRIVER_VERSION-linux64.tar.gz
###< symfony/panther ###

The command RUN apk add --no-cache chromium chromium-chromedriver keeps failing because apk command doesn't exist. I am Docker noob, so trying to solve this problem showed me that apk is related to alpine (not recommended version). Replacing that line with this:

RUN apt-get update && apt-get install -y --no-install-recommends chromium chromium-chromedriver

failed with Unable to locate package chromium-chromedriver message.

At this point I am out of ideas. Any help?

zmitic avatar Mar 13 '24 15:03 zmitic