X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=blobdiff_plain;f=docker%2FDockerfile;h=248a6ab05c4f52b496f7738138a4471ce43cf5b3;hb=355f6833772f06b7935c58d2b15f9a1f3409c28b;hp=5387babffd54925ff704f9836988b7fe409b1a7b;hpb=0fe4dff8af1fe44f7b7c7fbf7df9034aba2c3062;p=yardstick.git diff --git a/docker/Dockerfile b/docker/Dockerfile index 5387babff..248a6ab05 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -11,6 +11,8 @@ FROM ubuntu:14.04 LABEL image=opnfv/yardstick +ARG BRANCH=master + # GIT repo directory ENV REPOS_DIR /home/opnfv/repos @@ -19,7 +21,9 @@ ENV YARDSTICK_REPO_DIR ${REPOS_DIR}/yardstick ENV RELENG_REPO_DIR ${REPOS_DIR}/releng RUN sed -i -e 's/^deb /deb [arch=amd64] /g' /etc/apt/sources.list RUN sed -i -e 's/^deb-src /# deb-src /g' /etc/apt/sources.list +RUN echo "APT::Default-Release \"trusty\";" > /etc/apt/apt.conf.d/default-distro RUN echo "\n\ +deb [arch=amd64] http://archive.ubuntu.com/ubuntu/ xenial-updates universe \n\ deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports/ trusty main universe multiverse restricted \n\ deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports/ trusty-updates main universe multiverse restricted \n\ deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports/ trusty-security main universe multiverse restricted \n\ @@ -28,7 +32,7 @@ RUN echo "vm.mmap_min_addr = 0" > /etc/sysctl.d/mmap_min_addr.conf RUN dpkg --add-architecture arm64 RUN apt-get update && apt-get install -y \ - qemu-user-static \ + qemu-user-static/xenial \ libc6:arm64 \ wget \ expect \ @@ -39,12 +43,17 @@ RUN apt-get update && apt-get install -y \ kpartx \ libffi-dev \ libssl-dev \ + libzmq-dev \ python \ python-dev \ libxml2-dev \ libxslt1-dev \ + nginx \ + uwsgi \ + uwsgi-plugin-python \ + supervisor \ python-setuptools && \ - easy_install -U setuptools + easy_install -U setuptools==30.0.0 RUN apt-get -y autoremove && \ apt-get clean @@ -52,15 +61,20 @@ RUN apt-get -y autoremove && \ RUN mkdir -p ${REPOS_DIR} RUN git config --global http.sslVerify false -RUN git clone https://gerrit.opnfv.org/gerrit/yardstick ${YARDSTICK_REPO_DIR} -RUN git clone https://gerrit.opnfv.org/gerrit/releng ${RELENG_REPO_DIR} +RUN git clone --depth 1 -b $BRANCH https://gerrit.opnfv.org/gerrit/yardstick ${YARDSTICK_REPO_DIR} +RUN git clone --depth 1 https://gerrit.opnfv.org/gerrit/releng ${RELENG_REPO_DIR} # install yardstick + dependencies RUN cd ${YARDSTICK_REPO_DIR} && easy_install -U pip -RUN cd ${YARDSTICK_REPO_DIR} && pip install -r tests/ci/requirements.txt +RUN cd ${YARDSTICK_REPO_DIR} && pip install -r requirements.txt RUN cd ${YARDSTICK_REPO_DIR} && pip install . -ADD http://download.cirros-cloud.net/0.3.3/cirros-0.3.3-x86_64-disk.img /home/opnfv/images/ +RUN ${YARDSTICK_REPO_DIR}/api/api-prepare.sh + +EXPOSE 5000 + +ADD http://download.cirros-cloud.net/0.3.5/cirros-0.3.5-x86_64-disk.img /home/opnfv/images/ ADD http://cloud-images.ubuntu.com/trusty/current/trusty-server-cloudimg-amd64-disk1.img /home/opnfv/images/ COPY ./exec_tests.sh /usr/local/bin/ +CMD ["/usr/bin/supervisord"]