Created
July 26, 2019 21:13
-
-
Save msabramo/2d5f18863db601e5ba6435f9405b9c63 to your computer and use it in GitHub Desktop.
Cypress test Dockerfile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# use Cypress provided image with all dependencies included | |
FROM cypress/base:10 | |
RUN node --version | |
RUN npm --version | |
RUN apt-get update && \ | |
apt-get install -y locales && \ | |
sed -i 's/^# *\(en_US.UTF-8\)/\1/' /etc/locale.gen && \ | |
locale-gen | |
ENV LC_ALL=en_US.UTF-8 | |
WORKDIR /usr/src/app | |
COPY package.json package-lock.json .npmrc ./ | |
# avoid many lines of progress bars during install | |
# https://github.com/cypress-io/cypress/issues/1243 | |
ENV CI=1 | |
ENV DEBUG=cypress:cli,xvfb | |
# install NPM dependencies and Cypress binary | |
RUN npm ci | |
# check if the binary was installed successfully | |
RUN $(npm bin)/cypress verify | |
COPY . /usr/src/app |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment