1 ##############################################################################
2 # Copyright (c) 2015 Ericsson AB and others.
4 # All rights reserved. This program and the accompanying materials
5 # are made available under the terms of the Apache License, Version 2.0
6 # which accompanies this distribution, and is available at
7 # http://www.apache.org/licenses/LICENSE-2.0
8 ##############################################################################
12 LABEL image=opnfv/yardstick
17 ENV REPOS_DIR /home/opnfv/repos
20 ENV YARDSTICK_REPO_DIR ${REPOS_DIR}/yardstick
21 ENV RELENG_REPO_DIR ${REPOS_DIR}/releng
22 RUN sed -i -e 's/^deb /deb [arch=amd64] /g' /etc/apt/sources.list
23 RUN sed -i -e 's/^deb-src /# deb-src /g' /etc/apt/sources.list
25 deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports/ trusty main universe multiverse restricted \n\
26 deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports/ trusty-updates main universe multiverse restricted \n\
27 deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports/ trusty-security main universe multiverse restricted \n\
28 deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports/ trusty-proposed main universe multiverse restricted" >> /etc/apt/sources.list
29 RUN echo "vm.mmap_min_addr = 0" > /etc/sysctl.d/mmap_min_addr.conf
30 RUN dpkg --add-architecture arm64
32 RUN apt-get update && apt-get install -y \
51 python-setuptools && \
52 easy_install -U setuptools
54 RUN apt-get -y autoremove && \
57 RUN mkdir -p ${REPOS_DIR}
59 RUN git config --global http.sslVerify false
60 RUN git clone --depth 1 -b $BRANCH https://gerrit.opnfv.org/gerrit/yardstick ${YARDSTICK_REPO_DIR}
61 RUN git clone --depth 1 https://gerrit.opnfv.org/gerrit/releng ${RELENG_REPO_DIR}
63 # install yardstick + dependencies
64 RUN cd ${YARDSTICK_REPO_DIR} && easy_install -U pip
65 RUN cd ${YARDSTICK_REPO_DIR} && pip install -r requirements.txt
66 RUN cd ${YARDSTICK_REPO_DIR} && pip install .
68 RUN ${YARDSTICK_REPO_DIR}/api/api-prepare.sh
72 ADD http://download.cirros-cloud.net/0.3.3/cirros-0.3.3-x86_64-disk.img /home/opnfv/images/
73 ADD http://cloud-images.ubuntu.com/trusty/current/trusty-server-cloudimg-amd64-disk1.img /home/opnfv/images/
75 COPY ./exec_tests.sh /usr/local/bin/