-
-
Notifications
You must be signed in to change notification settings - Fork 44
/
Copy pathDockerfile.base
59 lines (49 loc) · 1.84 KB
/
Dockerfile.base
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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
FROM --platform=linux/amd64 ubuntu:22.04
LABEL maintainer="[email protected]"
# Install selenium
ENV LC_ALL C
ENV DEBIAN_FRONTEND noninteractive
ENV DEBCONF_NONINTERACTIVE_SEEN true
RUN useradd -d /home/seleuser -m seleuser
RUN chown -R seleuser /home/seleuser
RUN chgrp -R seleuser /home/seleuser
WORKDIR /home/seleuser
RUN apt-get update -y && \
apt-get install -yq --no-install-recommends \
gnupg \
software-properties-common \
python3.10 \
python3-pip && \
add-apt-repository -y ppa:openjdk-r/ppa && \
apt-get install -yq --no-install-recommends \
curl \
wget \
xvfb \
libxi6 \
libgconf-2-4 \
default-jdk && \
rm -rf /var/lib/apt/lists/*
# https://www.ubuntuupdates.org/package/google_chrome/stable/main/base/google-chrome-stable for references around the latest versions
RUN curl -sS -o - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add
RUN echo "deb [arch=amd64] https://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list
RUN apt-get update -y && apt-get install -yq \
google-chrome-stable=121.0.6167.85-1 \
unzip && \
rm -rf /var/lib/apt/lists/*
RUN wget -q https://chromedriver.storage.googleapis.com/113.0.5672.63/chromedriver_linux64.zip
RUN unzip chromedriver_linux64.zip
RUN rm -f chromedriver_linux64.zip
RUN mv chromedriver /usr/bin/chromedriver
RUN chown root:root /usr/bin/chromedriver
RUN chmod +x /usr/bin/chromedriver
RUN wget -q https://github.com/SeleniumHQ/selenium/releases/download/selenium-4.4.0/selenium-server-4.4.0.jar
RUN wget -q https://repo1.maven.org/maven2/org/testng/testng/7.6.1/testng-7.6.1.jar
# Install DocSearch dependencies
COPY Pipfile .
COPY Pipfile.lock .
ENV LC_ALL C.UTF-8
ENV LANG C.UTF-8
ENV PIPENV_HIDE_EMOJIS 1
RUN pip3 install pipenv
USER 1000
RUN pipenv sync --python 3.10