Skip to content

Instantly share code, notes, and snippets.

@d-sea
Created Mar 31, 2021
Embed
What would you like to do?
Ruby on Rails Docker file (Ruby on Rails + Vue.js + MySQL)
FROM ruby:2.6.6
# Japanese fonts
RUN apt-get update && apt-get install -y locales && \
locale-gen ja_JP.UTF-8 && \
apt-get install -y fonts-vlgothic
ENV LANG ja_JP.UTF-8
ENV LC_CTYPE ja_JP.UTF-8
RUN localedef -f UTF-8 -i ja_JP ja_JP.utf8
# chrome
RUN apt-get update && apt-get install -y unzip && \
CHROME_DRIVER_VERSION=`curl -sS chromedriver.storage.googleapis.com/LATEST_RELEASE` && \
wget -N http://chromedriver.storage.googleapis.com/$CHROME_DRIVER_VERSION/chromedriver_linux64.zip -P ~/ && \
unzip ~/chromedriver_linux64.zip -d ~/ && \
rm ~/chromedriver_linux64.zip && \
chown root:root ~/chromedriver && \
chmod 755 ~/chromedriver && \
mv ~/chromedriver /usr/bin/chromedriver && \
sh -c 'wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add -' && \
sh -c 'echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list' && \
apt-get update && apt-get install -y google-chrome-stable
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment