From b4e9f56db4a18268c8bc1c5bdbf4eeead06e7755 Mon Sep 17 00:00:00 2001 From: Steven Dake Date: Sun, 16 Aug 2015 14:48:58 -0700 Subject: [PATCH] Templatize Murano container Murano is not available in RDO so only from source install works. Change-Id: I77aacea53b8e7782c04495f43ea7e668eaee06ab Partially-implements: blueprint dockerfile-template --- .../murano/murano-api/Dockerfile.j2 | 8 +++++++ .../murano/murano-api/config-external.sh | 1 + docker_templates/murano/murano-api/start.sh | 1 + .../murano/murano-base/Dockerfile.j2 | 23 +++++++++++++++++++ .../murano/murano-engine/Dockerfile.j2 | 8 +++++++ .../murano/murano-engine/config-external.sh | 1 + .../murano/murano-engine/start.sh | 1 + 7 files changed, 43 insertions(+) create mode 100644 docker_templates/murano/murano-api/Dockerfile.j2 create mode 120000 docker_templates/murano/murano-api/config-external.sh create mode 120000 docker_templates/murano/murano-api/start.sh create mode 100644 docker_templates/murano/murano-base/Dockerfile.j2 create mode 100644 docker_templates/murano/murano-engine/Dockerfile.j2 create mode 120000 docker_templates/murano/murano-engine/config-external.sh create mode 120000 docker_templates/murano/murano-engine/start.sh diff --git a/docker_templates/murano/murano-api/Dockerfile.j2 b/docker_templates/murano/murano-api/Dockerfile.j2 new file mode 100644 index 0000000000..704743b4dd --- /dev/null +++ b/docker_templates/murano/murano-api/Dockerfile.j2 @@ -0,0 +1,8 @@ +FROM {{ namespace }}/{{ base_distro }}-{{ install_type }}-murano-base:{{ tag }} +MAINTAINER Kolla Project (https://launchpad.net/kolla) + +COPY config-external.sh /opt/kolla/ + +COPY start.sh / + +CMD ["/start.sh"] diff --git a/docker_templates/murano/murano-api/config-external.sh b/docker_templates/murano/murano-api/config-external.sh new file mode 120000 index 0000000000..508c2d5641 --- /dev/null +++ b/docker_templates/murano/murano-api/config-external.sh @@ -0,0 +1 @@ +../../../docker/common/murano/murano-api/config-external.sh \ No newline at end of file diff --git a/docker_templates/murano/murano-api/start.sh b/docker_templates/murano/murano-api/start.sh new file mode 120000 index 0000000000..00416066a9 --- /dev/null +++ b/docker_templates/murano/murano-api/start.sh @@ -0,0 +1 @@ +../../../docker/common/murano/murano-api/start.sh \ No newline at end of file diff --git a/docker_templates/murano/murano-base/Dockerfile.j2 b/docker_templates/murano/murano-base/Dockerfile.j2 new file mode 100644 index 0000000000..bca9b6d033 --- /dev/null +++ b/docker_templates/murano/murano-base/Dockerfile.j2 @@ -0,0 +1,23 @@ +FROM {{ namespace }}/{{ base_distro }}-{{ install_type }}-base:{{ tag }} +MAINTAINER Kolla Project (https://launchpad.net/kolla) + +{% if install_type == 'binary' %} + +RUN echo '{{ install_type }} not yet available for {{ base_distro }}' \ + && /bin/false + +{% elif install_type == 'source' %} + +ADD ./murano.tar / +RUN ln -s /murano-* /murano + +RUN cd /murano \ + && pip install -r requirements.txt \ + && pip install /murano \ + && mkdir /etc/murano \ + && cd /murano \ + && tox -e genconfig \ + && cp -r etc/murano/* /etc/murano/ \ + && rm -rf /root/.cache + +{% endif %} diff --git a/docker_templates/murano/murano-engine/Dockerfile.j2 b/docker_templates/murano/murano-engine/Dockerfile.j2 new file mode 100644 index 0000000000..704743b4dd --- /dev/null +++ b/docker_templates/murano/murano-engine/Dockerfile.j2 @@ -0,0 +1,8 @@ +FROM {{ namespace }}/{{ base_distro }}-{{ install_type }}-murano-base:{{ tag }} +MAINTAINER Kolla Project (https://launchpad.net/kolla) + +COPY config-external.sh /opt/kolla/ + +COPY start.sh / + +CMD ["/start.sh"] diff --git a/docker_templates/murano/murano-engine/config-external.sh b/docker_templates/murano/murano-engine/config-external.sh new file mode 120000 index 0000000000..7b42bd825d --- /dev/null +++ b/docker_templates/murano/murano-engine/config-external.sh @@ -0,0 +1 @@ +../../../docker/common/murano/murano-engine/config-external.sh \ No newline at end of file diff --git a/docker_templates/murano/murano-engine/start.sh b/docker_templates/murano/murano-engine/start.sh new file mode 120000 index 0000000000..160b196265 --- /dev/null +++ b/docker_templates/murano/murano-engine/start.sh @@ -0,0 +1 @@ +../../../docker/common/murano/murano-engine/start.sh \ No newline at end of file