# K8S config file
K8S_CREDENTIALS=<path_to_kubeconfig>
-# Juju data file
-JUJU_DATA=<path_to_jujudata>
-
# The following set of environment variables will be used in host
# of the robot framework. Not needed for docker execution
* <path_to_clouds.yaml> [OPTIONAL]: It is the absolute path to the clouds.yaml file in the host
* <path_to_sdncs.yaml> [OPTIONAL]: It is the absolute path to the sdncs.yaml file in the host
* <path_to_kubeconfig> [OPTIONAL]: It is the kubeconfig file to be used for k8s clusters
-* <path_to_jujudata> [OPTIONAL]: It is the jujudata file to be used for juju cli
```bash
docker run --rm=true -t osmtests --env-file <env_file> \
-v <path_to_clouds.yaml>:/robot-systest/clouds.yaml \
-v <path_to_sdncs.yaml>:/robot-systest/sdncs.yaml \
-v <path_to_kubeconfig>:/root/.kube/config \
- -v <path_to_jujudata>:/root/.local/share/juju \
-o <osmclient_version> \
-p <package_branch> \
-t <testing_tags>
RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get -y install git software-properties-common \
make python3 debhelper python3-pip apt-utils ssh iputils-ping libcurl4-openssl-dev libssl-dev cargo rustc
-# Installing Juju
-ARG JUJU_VERSION_M=2.8
-ARG JUJU_VERSION_R=11
-ARG JUJU_VERSION=$JUJU_VERSION_M.$JUJU_VERSION_R
-
-RUN curl --output /tmp/juju-$JUJU_VERSION-linux-amd64.tar.xz -LO \
- https://launchpad.net/juju/$JUJU_VERSION_M/$JUJU_VERSION/+download/juju-$JUJU_VERSION-linux-amd64.tar.xz && \
- tar -xf /tmp/juju-$JUJU_VERSION-linux-amd64.tar.xz -C /tmp && \
- install /tmp/juju /usr/local/bin/juju && \
- rm /tmp/juju /tmp/juju-$JUJU_VERSION-linux-amd64.tar.xz
-
-RUN add-apt-repository -y ppa:rmescandon/yq && apt update && apt install yq -y
+RUN add-apt-repository -y ppa:rmescandon/yq && apt update && apt install yq -y
RUN python3 -m pip install -U pip
# Kubeconfig file
ENV K8S_CREDENTIALS=/root/.kube/config
-# Juju data folder
-ENV JUJU_DATA=/root/.local/share/juju
-
# OSM RSA file
ENV OSM_RSA_FILE=/root/osm_id_rsa
-v <path_to_reports>:/reports osmtests \\
-v <path_to_clouds.yaml>:/robot-systest/clouds.yaml \\
-v <path_to_kubeconfig>:/root/.kube/config \\
- -v <path_to_jujudata>:/root/.local/share/juju \\
-o <osmclient_version> \\
-p <package_branch> \\
-t <testing_tags>
Volumes:
<path_to_reports> [OPTIONAL]: It is the absolute path to reports location in the host
<path_to_clouds.yaml> [OPTIONAL]: It is the absolute path to the clouds.yaml file in the host
- <path_to_kubeconfig> [OPTIONAL]: It is the kubeconfig file to be used for k8s clusters
- <path_to_jujudata> [OPTIONAL]: It is the jujudata file to be used for juju cli"
+ <path_to_kubeconfig> [OPTIONAL]: It is the kubeconfig file to be used for k8s clusters"
exit 0
;;