Fix RabbitMQ service installation and initialization 49/54549/3
authorRodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
Wed, 28 Mar 2018 11:13:35 +0000 (12:13 +0100)
committerRodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
Wed, 28 Mar 2018 11:24:30 +0000 (11:24 +0000)
RabbitMQ service added in [1] is not correctly installed and initialized:
- There is an error during the installation process ("\" character
  missing).
- In the installation script, the service needs to be started first.
- In the container installation, the service needs to be started via
  supervisor.

[1]https://gerrit.opnfv.org/gerrit/#/c/53597/

JIRA: YARDSTICK-1103

Change-Id: Iade3d6ce4b522e6f576af71b7afe5559081f7929
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
docker/supervisor.sh
install.sh

index b67de22..1e54b41 100755 (executable)
@@ -24,3 +24,6 @@ directory = /etc/yardstick
 command = uwsgi -i yardstick.ini
 EOF
 fi
+
+[program:rabbitmq]
+command = service rabbitmq-server restart
index 6f4ab8c..04985f4 100755 (executable)
@@ -84,7 +84,7 @@ apt-get update && apt-get install -y \
     libxft-dev \
     libxss-dev \
     sudo \
-    iputils-ping
+    iputils-ping \
     rabbitmq-server
 
 if [[ "${DOCKER_ARCH}" != "aarch64" ]]; then
@@ -95,10 +95,11 @@ apt-get -y autoremove && apt-get clean
 
 git config --global http.sslVerify false
 
-# Configure and restart RabbitMQ
+# Start and configure RabbitMQ
+service rabbitmq-server restart
+rabbitmqctl start_app
 rabbitmqctl add_user yardstick yardstick
 rabbitmqctl set_permissions yardstick ".*" ".*" ".*"
-rabbitmqctl reset
 
 # install yardstick + dependencies
 easy_install -U pip==9.0.1