Skip to content

Instantly share code, notes, and snippets.

@cupnoodle
Last active November 7, 2019 09:08
Show Gist options
  • Save cupnoodle/371329f59f95d0d2ad34c0438e350f98 to your computer and use it in GitHub Desktop.
Save cupnoodle/371329f59f95d0d2ad34c0438e350f98 to your computer and use it in GitHub Desktop.
Ruby 2.5.0 + Chrome webdriver + nodejs / yarn
FROM ruby:2.5.0
ENV CHROMIUM_DRIVER_VERSION 75.0.3770.90
ENV CHROME_VERSION 75.0.3770.90-1
RUN apt-get update && apt-get install -y --no-install-recommends wget xvfb xauth unzip \
&& wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add - \
&& echo "deb http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list \
&& apt-get update -y \
&& wget http://dl.google.com/linux/deb/pool/main/g/google-chrome-unstable/google-chrome-unstable_${CHROME_VERSION}_amd64.deb \
&& apt-get install -y -f ./google-chrome-unstable_${CHROME_VERSION}_amd64.deb \
&& wget -q --continue -P /usr/local/bin "https://chromedriver.storage.googleapis.com/$CHROMIUM_DRIVER_VERSION/chromedriver_linux64.zip" \
&& unzip /usr/local/bin/chromedriver* -d /usr/local/bin \
&& rm /usr/local/bin/chromedriver*.zip \
&& apt-get -y install g++ qt5-default libqt5webkit5-dev gstreamer1.0-plugins-base gstreamer1.0-tools gstreamer1.0-x libxml2-dev libxslt1-dev \
&& curl -sL https://deb.nodesource.com/setup_8.x | bash - \
&& apt-get install -y nodejs \
&& curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - \
&& echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list \
&& apt-get update \
&& apt-get install yarn \
\
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment