## Global args (persist through multi-stage builds) can be passed in via CLI or set here
## This version will always be the latest version Provar has made publicly available.
ARG PROVAR_DEFAULT_VERSION=latest
ARG PROVAR_MAJOR_VERSION=latest
## This should be your project’s name
ARG PROJECT_NAME=SeleniumGrid
## This docker build assumes you run as root (-u root)
FROM debian:stretch-slim

LABEL maintainer “Provar Testing <onboarding.us@provartesting.com>”
ARG PROVAR_DEFAULT_VERSION
ARG PROVAR_MAJOR_VERSION
ARG PROJECT_NAME
# The location to save the Provar binaries to (from downloads page)
ENV REPO_HOME=/srv/Provar \
PROVAR_VERSION=${PROVAR_DEFAULT_VERSION}

## Install wget & unzip
RUN set -ex \
&& apt update && apt install -y \
wget \
unzip

## Install Provar SDK: ~411 MB Uncompressed
RUN set -ex \
mkdir -p ${REPO_HOME}/Provar_ANT_${PROVAR_DEFAULT_VERSION} \
&& wget -qP ${REPO_HOME} https://download.provartesting.com/${PROVAR_MAJOR_VERSION}/Provar_ANT_${PROVAR_DEFAULT_VERSION}.zip \
&& unzip ${REPO_HOME}/Provar_ANT_${PROVAR_DEFAULT_VERSION}.zip -d ${REPO_HOME}/Provar_ANT_${PROVAR_DEFAULT_VERSION} \