1
1
FROM ubuntu:20.04
2
2
3
+ ARG NODE_VERSION=10
4
+
3
5
ENV DEBIAN_FRONTEND noninteractive
4
- ENV NODE_OPTIONS --max_old_space_size=4096
6
+ ENV NODE_OPTIONS --max_old_space_size=4096 --use-openssl-ca
7
+
8
+ # Configuring NodeJS version
9
+ RUN apt-get clean
10
+
11
+ RUN apt-get update && \
12
+ apt-get upgrade -y && \
13
+ apt-get install -y curl
14
+
15
+ RUN curl -sL https://deb.nodesource.com/setup_${NODE_VERSION:=10}.x | sh
5
16
6
17
RUN apt-get update && \
18
+ apt-get upgrade -y && \
7
19
apt-get install -y \
8
20
git \
9
21
curl \
10
22
python3 \
11
23
nodejs \
12
- npm \
13
24
firefox \
25
+ nodejs \
14
26
&& rm -rf /var/lib/apt/lists/*
15
27
16
- RUN npm install -g npm@7 \
17
- && /bin/bash -c "hash -d npm"
28
+ RUN /bin/bash -c "hash -d npm"
18
29
19
30
# Enable tls v1.0
20
31
RUN echo "openssl_conf = openssl_configuration\n " |cat - /etc/ssl/openssl.cnf > /tmp/openssl_conf.cnf \
@@ -31,14 +42,20 @@ CipherString = DEFAULT:@SECLEVEL=1" >> /etc/ssl/openssl.cnf
31
42
COPY CAs/* /usr/local/share/ca-certificates/
32
43
# Store custom CAs somewhere where the backend can find them later.
33
44
COPY CustomCAs/* /usr/local/share/custom-ca-certificates/
34
- RUN update-ca-certificates
45
+
46
+ RUN update-ca-certificates --verbose
35
47
36
48
# Creating an user for building the driver and running the tests
37
49
RUN useradd -m driver && echo "driver:driver" | chpasswd && adduser driver sudo
38
50
VOLUME /driver
39
- RUN chown -Rh driver:driver /driver
51
+ RUN chown -Rh driver:driver /home/driver
52
+ WORKDIR /home/driver
53
+
40
54
USER driver
41
55
WORKDIR /home/driver
42
56
CMD /bin/bash
43
57
RUN mkdir /home/driver/.npm_global
44
58
RUN npm config set prefix /home/driver/.npm_global
59
+
60
+ RUN node --version
61
+ RUN npm --version
0 commit comments