Fix ansible scripts for running in container 27/57027/2
authorJohn O Loughlin <john.oloughlin@intel.com>
Thu, 3 May 2018 13:19:29 +0000 (14:19 +0100)
committerJohn O'Loughlin <john.oloughlin@intel.com>
Thu, 3 May 2018 16:32:28 +0000 (16:32 +0000)
JIRA: YARDSTICK-1147

Change-Id: I52dae85a2d97192bc8a48c5aeea3173b3d4de003
Signed-off-by: John O Loughlin <john.oloughlin@intel.com>
ansible/roles/add_repos_jumphost/tasks/Debian.yml
docker/Dockerfile

index 0b67c66..626f0b0 100644 (file)
@@ -37,8 +37,7 @@
     replace: "# deb-src "
 
 - name: Add extra architecture
-  apt:
-    dpkg_options: "add-architecture {{ extra_arch }}"
+  command: "dpkg --add-architecture {{ extra_arch }}"
 
 - name: Define the default release version
   copy:
index 098877c..5813f02 100644 (file)
@@ -31,13 +31,16 @@ RUN pip install appdirs==1.4.0 pyopenssl==17.5.0 python-openstackclient==3.11.0
 RUN mkdir -p ${REPOS_DIR}
 
 RUN git config --global http.sslVerify false
-##RUN git clone --depth 1 -b $BRANCH https://gerrit.opnfv.org/gerrit/yardstick ${YARDSTICK_REPO_DIR}
-RUN mkdir ${YARDSTICK_REPO_DIR}
-COPY ./ ${YARDSTICK_REPO_DIR}
+#For developers: To test your changes you must comment out the git clone for ${YARDSTICK_REPO_DIR}.
+#You must also uncomment the RUN and COPY commands below.
+#You must run docker build from your yardstick directory on the host.
+RUN git clone --depth 1 -b $BRANCH https://gerrit.opnfv.org/gerrit/yardstick ${YARDSTICK_REPO_DIR}
+#RUN mkdir ${YARDSTICK_REPO_DIR}
+#COPY ./ ${YARDSTICK_REPO_DIR}
 RUN git clone --depth 1 https://gerrit.opnfv.org/gerrit/releng ${RELENG_REPO_DIR}
 RUN git clone --depth 1 -b $BRANCH https://gerrit.opnfv.org/gerrit/storperf ${STORPERF_REPO_DIR}
 
-RUN ansible-playbook -vvv -e INSTALLATION_MODE="container" ${YARDSTICK_REPO_DIR}/ansible/install.yaml
+RUN ansible-playbook -c local -vvv -e INSTALLATION_MODE="container" ${YARDSTICK_REPO_DIR}/ansible/install.yaml
 
 RUN ${YARDSTICK_REPO_DIR}/docker/supervisor.sh