Improve script to download latest version of chromedriver automatically

This commit is contained in:
Boni Garcia 2018-07-05 12:56:10 +02:00
parent 84ac59f66a
commit 1d7b7c2ac7
2 changed files with 8 additions and 8 deletions

View file

@ -91,11 +91,11 @@ RUN rm ${ANDROID_HOME}/tools/emulator \
ENV LD_LIBRARY_PATH=$ANDROID_HOME/emulator/lib64:$ANDROID_HOME/emulator/lib64/qt/lib
#==============================================
# Download chrome driver
# to be able to use chrome browser in emulator
# Issue: https://github.com/butomo1989/docker-android/commit/6406504f944dae73d0a0c5d8e71a17a47dff9b33
# Download latest version of chromedriver
# to be able to use Chrome browser in emulator
#==============================================
RUN wget -nv -O chrome.zip "https://chromedriver.storage.googleapis.com/2.40/chromedriver_linux64.zip" \
RUN LATEST_VERSION=$(curl -s https://chromedriver.storage.googleapis.com/LATEST_RELEASE) \
&& wget -nv -O chrome.zip "https://chromedriver.storage.googleapis.com/$LATEST_VERSION/chromedriver_linux64.zip" \
&& unzip -x chrome.zip \
&& rm chrome.zip

View file

@ -105,11 +105,11 @@ ENV LD_LIBRARY_PATH=$ANDROID_HOME/emulator/lib64:$ANDROID_HOME/emulator/lib64/qt
#==============================================
# Download chrome driver
# to be able to use chrome browser in emulator
# Issue: https://github.com/butomo1989/docker-android/commit/6406504f944dae73d0a0c5d8e71a17a47dff9b33
# Download latest version of chromedriver
# to be able to use Chrome browser in emulator
#==============================================
RUN wget -nv -O chrome.zip "https://chromedriver.storage.googleapis.com/2.40/chromedriver_linux64.zip" \
RUN LATEST_VERSION=$(curl -s https://chromedriver.storage.googleapis.com/LATEST_RELEASE) \
&& wget -nv -O chrome.zip "https://chromedriver.storage.googleapis.com/$LATEST_VERSION/chromedriver_linux64.zip" \
&& unzip -x chrome.zip \
&& rm chrome.zip