diff options
author | Yujun Zhang <zhang.yujunz@zte.com.cn> | 2018-01-08 10:48:42 +0800 |
---|---|---|
committer | Yujun Zhang <zhang.yujunz@zte.com.cn> | 2018-01-08 10:55:30 +0800 |
commit | 0436f87ff05b0835e1ed75ee2955f5097e572224 (patch) | |
tree | df1ec4d5dc688e100a77c6326d98ba0b0d4d3990 /docker | |
parent | ea7c2467b1c5d24ac56c41a2ab82355d01cf3cc2 (diff) |
Fix "qtip command not found" in Docker container
- updated dependency lock
- allow buidling docker image from local repository
- use pip to install local package
Change-Id: I9eecae54f278e57ec0ba4840b2d64abb0134d9b6
JIRA: QTIP-289
Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
Diffstat (limited to 'docker')
-rw-r--r-- | docker/Dockerfile.local | 63 |
1 files changed, 63 insertions, 0 deletions
diff --git a/docker/Dockerfile.local b/docker/Dockerfile.local new file mode 100644 index 00000000..86e86dcd --- /dev/null +++ b/docker/Dockerfile.local @@ -0,0 +1,63 @@ +########################################## +#####Docker container for QTIP############ +########################################## + +FROM ubuntu:16.04 +MAINTAINER QTIP Team <https://wiki.opnfv.org/display/qtip> +LABEL version="0.1" description="OPNFV QTIP Docker container" + +ARG BRANCH=master + +ENV REPOS_DIR=/home/opnfv/repos \ + PYTHONPATH=/home/opnfv/repos/qtip \ + USER=root + +WORKDIR /home/opnfv + +RUN mkdir -p ${REPOS_DIR} \ + && mkdir -p /root/qtip/logs \ + && mkdir -p /root/.ssh \ + && chmod 700 /root/.ssh + +# Packaged Dependencies +RUN apt-get update && apt-get install -y \ + software-properties-common \ + git \ + gcc \ + build-essential\ + libssl-dev\ + libffi-dev\ + locales \ + supervisor \ + python-dev \ + python-pip \ + python-setuptools \ + rsync \ + iputils-ping \ + wget \ + curl \ + openssh-client \ + --no-install-recommends \ + && rm -rf /var/lib/apt/lists/* + +RUN locale-gen en_US en_US.UTF-8 \ + && pip install -U pip \ + && pip install -U setuptools + +COPY . $REPOS_DIR/qtip + +RUN cd $REPOS_DIR/qtip \ + && pip install pipenv \ + && pip install -e . \ + && pipenv install --system + +RUN echo 'eval $(ssh-agent)' >> /root/.bashrc + +# Exposing ports +EXPOSE 5000 + +#Config supervisor +RUN mkdir -p /var/log/supervisor +COPY docker/supervisord.conf /etc/supervisor/conf.d/supervisord.conf + +CMD ["/usr/bin/supervisord"] |