From 18f1f068f534aaa8937024b7060e902bd036c559 Mon Sep 17 00:00:00 2001 From: Eduardo Gonzalez Date: Tue, 15 Aug 2017 16:13:56 +0200 Subject: [PATCH] Add redis and tacker to mistral-base Install redis for mistral coordination backend. Install tacker for mistral tacker actions. Change-Id: I1613939b07eb060d3ec4d8a6cd575ce43616c680 Closes-Bug: #1700591 --- docker/mistral/mistral-base/Dockerfile.j2 | 26 ++++++++++++++++++----- kolla/common/config.py | 4 ++++ 2 files changed, 25 insertions(+), 5 deletions(-) diff --git a/docker/mistral/mistral-base/Dockerfile.j2 b/docker/mistral/mistral-base/Dockerfile.j2 index 8ec9336089..1fd1f309cc 100644 --- a/docker/mistral/mistral-base/Dockerfile.j2 +++ b/docker/mistral/mistral-base/Dockerfile.j2 @@ -10,26 +10,42 @@ LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build {% if install_type == 'binary' %} {% if base_distro in ['centos', 'oraclelinux', 'rhel'] %} - {% set mistral_base_packages = ['openstack-mistral-common'] %} + {% set mistral_base_packages = [ + 'openstack-mistral-common', + 'openstack-tacker', + 'redis', + ] %} +# Note(egonzalez): Ubuntu does not have tacker packages yet. {% elif base_distro in ['debian', 'ubuntu'] %} - {% set mistral_base_packages = ['mistral-common'] %} + {% set mistral_base_packages = [ + 'mistral-common', + 'redis-server' + ] %} {% endif %} {{ macros.install_packages(mistral_base_packages | customizable("packages")) }} {% elif install_type == 'source' %} ADD mistral-base-archive /mistral-base-source +ADD plugins-archive / {% set mistral_base_pip_packages = [ - '/mistral' + '/mistral', + 'redis' +] %} + +{% set mistral_base_plugins_pip_packages = [ + '/plugins/*' ] %} RUN ln -s mistral-base-source/* mistral \ && {{ macros.install_pip(mistral_base_pip_packages | customizable("pip_packages"), constraints = false) }} \ && mkdir -p /etc/mistral \ && cp -r /mistral/etc/* /etc/mistral/ \ - && chown -R mistral: /etc/mistral - + && chown -R mistral: /etc/mistral \ + && if [ "$(ls /plugins)" ]; then \ + {{ macros.install_pip(mistral_base_plugins_pip_packages) }}; \ + fi {% endif %} COPY extend_start.sh /usr/local/bin/kolla_extend_start diff --git a/kolla/common/config.py b/kolla/common/config.py index 811a06de6b..10263e9428 100755 --- a/kolla/common/config.py +++ b/kolla/common/config.py @@ -467,6 +467,10 @@ SOURCES = { 'type': 'url', 'location': ('$tarballs_base/mistral/' 'mistral-master.tar.gz')}, + 'mistral-base-plugin-tacker': { + 'type': 'url', + 'location': ('$tarballs_base/tacker/' + 'tacker-master.tar.gz')}, 'monasca-api': { 'type': 'url', 'location': ('$tarballs_base/monasca-api/'