summaryrefslogtreecommitdiffstats
path: root/docker
diff options
context:
space:
mode:
Diffstat (limited to 'docker')
-rw-r--r--docker/Dockerfile47
-rw-r--r--docker/README.md11
-rw-r--r--docker/cleanup_qtip_image.sh24
-rw-r--r--docker/prepare_qtip_image.sh49
-rwxr-xr-xdocker/push_db.sh3
-rwxr-xr-xdocker/run_qtip.sh39
6 files changed, 22 insertions, 151 deletions
diff --git a/docker/Dockerfile b/docker/Dockerfile
index 369fa6c8..f2a543e6 100644
--- a/docker/Dockerfile
+++ b/docker/Dockerfile
@@ -2,8 +2,7 @@
#####Docker container for QTIP############
##########################################
-
-FROM ubuntu:14.04
+FROM ubuntu:16.04
MAINTAINER Yujun Zhang <zhang.yujunz@zte.com.cn>
LABEL version="0.1" description="OPNFV QTIP Docker container"
@@ -17,31 +16,31 @@ WORKDIR /home/opnfv
# Packaged Dependencies
RUN apt-get update && apt-get install -y \
-software-properties-common \
-wget \
-git \
-gcc \
-ssh \
-expect \
-python-matplotlib \
-python-dev \
-python-pip \
-libjpeg62 \
-libjpeg62-dev \
-zlib1g-dev \
-python-tk \
-curl \
-supervisor \
-python-setuptools \
---no-install-recommends
-
+ software-properties-common \
+ wget \
+ git \
+ gcc \
+ ssh \
+ expect \
+ python-matplotlib \
+ python-dev \
+ python-pip \
+ libjpeg62 \
+ libjpeg62-dev \
+ zlib1g-dev \
+ python-tk \
+ curl \
+ supervisor \
+ python-setuptools \
+ --no-install-recommends \
+&& rm -rf /var/lib/apt/lists/*
+
+RUN pip install -U pip
RUN pip install 'setuptools>=17.1'
RUN apt-add-repository ppa:ansible/ansible -y
RUN apt-key update -y
-RUN apt-get update -y
-RUN apt-get install ansible --force-yes -y
-
+RUN apt-get update && apt-get install ansible -y
RUN mkdir -p ${REPOS_DIR}
RUN mkdir -p /root/.ssh
@@ -54,7 +53,6 @@ RUN chmod 700 /root/.ssh
COPY ansible.cfg.default /root/.ansible.cfg
#Cloning Repos
-
RUN git config --global http.sslVerify false
RUN git clone -b $BRANCH https://gerrit.opnfv.org/gerrit/qtip $REPOS_DIR/qtip
RUN git clone https://gerrit.opnfv.org/gerrit/releng $REPOS_DIR/releng
@@ -62,7 +60,6 @@ RUN git clone https://gerrit.opnfv.org/gerrit/releng $REPOS_DIR/releng
RUN pip install -r $REPOS_DIR/qtip/requirements.txt
#Config supervisor
-
RUN mkdir -p /var/log/supervisor
RUN locale-gen en_US en_US.UTF-8
COPY supervisord.conf /etc/supervisor/conf.d/supervisord.conf
diff --git a/docker/README.md b/docker/README.md
deleted file mode 100644
index 35ac0935..00000000
--- a/docker/README.md
+++ /dev/null
@@ -1,11 +0,0 @@
-# QTIP The Indices for Performance
-
-[QTIP] is an [OPNFV] project.
-
-It aims to build a platform for creating and sharing indices of [NFVI] performance.
-
-See the [project vision](https://wiki.opnfv.org/display/qtip/Vision) for more details.
-
-[QTIP]: https://wiki.opnfv.org/display/qtip
-[OPNFV]: https://www.opnfv.org
-[NFVI]: https://en.wikipedia.org/wiki/Network_function_virtualization
diff --git a/docker/cleanup_qtip_image.sh b/docker/cleanup_qtip_image.sh
deleted file mode 100644
index 9c2b59db..00000000
--- a/docker/cleanup_qtip_image.sh
+++ /dev/null
@@ -1,24 +0,0 @@
-#!/bin/bash
-
-if [[ ! -f ${QTIP_DIR}/openrc ]];then
- source ${REPOS_DIR}/releng/utils/fetch_os_creds.sh \
- -d ${QTIP_DIR}/openrc \
- -i ${INSTALLER_TYPE} \
- -a ${INSTALLER_IP}
-fi
-
-source ${QTIP_DIR}/openrc
-
-cleanup_image()
-{
- echo
- if ! glance image-list; then
- return
- fi
-
- echo "Deleting image QTIP_CentOS..."
- glance image-delete $(glance image-list | grep -e QTIP_CentOS | awk '{print $2}')
-
-}
-
-cleanup_image
diff --git a/docker/prepare_qtip_image.sh b/docker/prepare_qtip_image.sh
deleted file mode 100644
index 4095c806..00000000
--- a/docker/prepare_qtip_image.sh
+++ /dev/null
@@ -1,49 +0,0 @@
-#!/bin/bash
-IMGNAME='QTIP_CentOS.qcow2'
-IMGPATH='/home/opnfv/imgstore'
-IMGURL='http://build.opnfv.org/artifacts.opnfv.org/qtip/QTIP_CentOS.qcow2'
-
-load_image()
-{
- if [[ -n $( glance image-list | grep -e QTIP_CentOS) ]]; then
- return
- fi
-
- test -d $IMGPATH || mkdir -p $IMGPATH
- if [[ ! -f "$IMGPATH/$IMGNAME" ]];then
- echo
- echo "========== Downloading QTIP_CentOS image =========="
- cd $IMGPATH
- wget -c --progress=dot:giga $IMGURL
- fi
-
- echo
- echo "========== Loading QTIP_CentOS image =========="
- output=$(glance image-create \
- --name QTIP_CentOS \
- --visibility public \
- --disk-format qcow2 \
- --container-format bare \
- --file $IMGPATH/$IMGNAME )
- echo "$output"
-
- IMAGE_ID=$(echo "$output" | grep " id " | awk '{print $(NF-1)}')
-
- if [ -z "$IMAGE_ID" ]; then
- echo 'Failed uploading QTIP_CentOS image to cloud'.
- exit 1
- fi
-
- echo "QTIP_CentOS image id: $IMAGE_ID"
-}
-
-rm -rf ${QTIP_DIR}/openrc
-
-${REPOS_DIR}/releng/utils/fetch_os_creds.sh \
--d ${QTIP_DIR}/openrc \
--i ${INSTALLER_TYPE} \
--a ${INSTALLER_IP}
-
-source ${QTIP_DIR}/openrc
-
-load_image
diff --git a/docker/push_db.sh b/docker/push_db.sh
deleted file mode 100755
index 50341eac..00000000
--- a/docker/push_db.sh
+++ /dev/null
@@ -1,3 +0,0 @@
-#!/bin/bash
-
-cd ${QTIP_DIR} && python qtip/utils/dashboard/pushtoDB.py
diff --git a/docker/run_qtip.sh b/docker/run_qtip.sh
deleted file mode 100755
index 98abf139..00000000
--- a/docker/run_qtip.sh
+++ /dev/null
@@ -1,39 +0,0 @@
-#! /bin/bash
-
-QTIP=qtip/run.py
-
-run_test_suite()
-{
- if [ "$TEST_CASE" == "compute" ]; then
- cd ${QTIP_DIR} && python ${QTIP} -l default -f compute
- cd ${QTIP_DIR} && python scripts/ref_results/suite_result.py compute
- elif [ "$TEST_CASE" == "storage" ]; then
- cd ${QTIP_DIR} && python ${QTIP} -l default -f storage
- cd ${QTIP_DIR} && python scripts/ref_results/suite_result.py storage
- elif [ "$TEST_CASE" == "network" ]; then
- cd ${QTIP_DIR} && python ${QTIP} -l default -f network
- cd ${QTIP_DIR} && python scripts/ref_results/suite_result.py network
- elif [ "$TEST_CASE" == "all" ]; then
- cd ${QTIP_DIR} && python ${QTIP} -l default -f compute
- cd ${QTIP_DIR} && python ${QTIP} -l default -f storage
- cd ${QTIP_DIR} && python ${QTIP} -l default -f network
-
- cd ${QTIP_DIR} && python scripts/ref_results/suite_result.py compute
- cd ${QTIP_DIR} && python scripts/ref_results/suite_result.py storage
- cd ${QTIP_DIR} && python scripts/ref_results/suite_result.py network
- fi
-}
-
-rm -f ${QTIP_DIR}/config/QtipKey*
-
-echo "Generating ssh keypair"
-ssh-keygen -t rsa -N "" -f ${QTIP_DIR}/config/QtipKey -q
-
-source ${QTIP_DIR}/docker/prepare_qtip_image.sh
-
-run_test_suite
-
-source ${QTIP_DIR}/docker/cleanup_qtip_image.sh
-
-echo "Remove ssh keypair"
-rm -f ${QTIP_DIR}/config/QtipKey*