File tree 2 files changed +14
-5
lines changed
2 files changed +14
-5
lines changed Original file line number Diff line number Diff line change @@ -131,11 +131,8 @@ RUN wget https://ftp.samba.org/pub/cwrap/nss_wrapper-1.1.2.tar.gz && \
131
131
RUN curl -sSL https://dl.google.com/linux/linux_signing_key.pub | apt-key add - \
132
132
&& echo "deb [arch=amd64] https://dl.google.com/linux/chrome/deb/ stable main" > /etc/apt/sources.list.d/google-chrome.list
133
133
RUN apt-get update && apt-get install -yq --no-install-recommends google-chrome-stable
134
- RUN wget https://chromedriver.storage.googleapis.com/74.0.3729.6/chromedriver_linux64.zip \
135
- && unzip chromedriver_linux64.zip \
136
- && mv chromedriver /usr/bin/chromedriver \
137
- && chmod 755 /usr/bin/chromedriver \
138
- && rm chromedriver_linux64.zip
134
+ COPY notebook/chromedriver.sh /root/chromedriver.sh
135
+ RUN chmod +x /root/chromedriver.sh && /root/chromedriver.sh
139
136
140
137
# Install R and some basic packages
141
138
RUN apt-get update && apt-get install -yq --no-install-recommends \
Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+
3
+ CHROME_VERSION=` /opt/google/chrome/chrome --version | cut -d ' ' -f 3`
4
+ CHROME_VERSION_MAJOR=` echo $CHROME_VERSION | cut -d ' .' -f 1`
5
+
6
+ CHROMEDRIVER_VERSION=` curl -s https://chromedriver.storage.googleapis.com/LATEST_RELEASE_${CHROME_VERSION_MAJOR} `
7
+
8
+ wget https://chromedriver.storage.googleapis.com/${CHROMEDRIVER_VERSION} /chromedriver_linux64.zip \
9
+ && unzip chromedriver_linux64.zip \
10
+ && mv chromedriver /usr/bin/chromedriver \
11
+ && chmod 755 /usr/bin/chromedriver \
12
+ && rm chromedriver_linux64.zip
You can’t perform that action at this time.
0 commit comments