forked from stolostron/grc-ui
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile.e2etest
43 lines (33 loc) · 1.13 KB
/
Dockerfile.e2etest
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
# Copyright (c) 2020 Red Hat, Inc.
FROM quay.io/ycao56/node:fermium
ENV NODE_ENV=development
ENV TERM=xterm-256color
USER root
RUN mkdir -p /opt/app-root/src/grc-ui
WORKDIR /opt/app-root/src/grc-ui
COPY cypress.json package.json ./
COPY tests ./tests
COPY build ./build
RUN mkdir -p /opt/app-root/src/grc-ui/cypress_cache
ENV CYPRESS_CACHE_FOLDER=/opt/app-root/src/grc-ui/cypress_cache
RUN apt-get update && apt-get install -y apache2-utils jq libgtk2.0-0 libgtk-3-0 libgbm-dev libnotify-dev libgconf-2-4 libnss3 libxss1 libasound2 libxtst6 xauth xvfb
# Install Chrome
RUN wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
RUN dpkg -i google-chrome-stable_current_amd64.deb; apt-get -fy install
RUN ./build/download-clis.sh
RUN npm install \
cypress-multi-reporters \
cypress-terminal-report \
cypress-wait-until \
cypress-fail-fast \
@cypress/code-coverage \
del \
mocha \
mocha-junit-reporter \
mochawesome \
js-yaml \
@slack/web-api
# Give write permissions for the directory
RUN chmod -R go+w /opt/app-root/src/grc-ui
CMD ["./build/run-docker-tests.sh"]