diff options
| author | Jenkins <jenkins@review.openstack.org> | 2016-07-08 12:06:57 +0000 |
|---|---|---|
| committer | Gerrit Code Review <review@openstack.org> | 2016-07-08 12:06:57 +0000 |
| commit | 56178a58dc1ea3f9117f4c03893ebafcf0e1f57c (patch) | |
| tree | 94f8e6f689ed0a0d85d893ddf46129c511373992 /docker/watcher/watcher-api | |
| parent | d4225830acba8a07fc4164fe9bc072c2cccd0a5d (diff) | |
| parent | 77296ebdeef833c875dfd57f5d43eb9cefee0cef (diff) | |
| download | kolla-56178a58dc1ea3f9117f4c03893ebafcf0e1f57c.tar.gz kolla-56178a58dc1ea3f9117f4c03893ebafcf0e1f57c.zip | |
Merge "Build docker images for OpenStack Watcher"
Diffstat (limited to 'docker/watcher/watcher-api')
| -rw-r--r-- | docker/watcher/watcher-api/Dockerfile.j2 | 16 | ||||
| -rw-r--r-- | docker/watcher/watcher-api/extend_start.sh | 8 |
2 files changed, 24 insertions, 0 deletions
diff --git a/docker/watcher/watcher-api/Dockerfile.j2 b/docker/watcher/watcher-api/Dockerfile.j2 new file mode 100644 index 000000000..fadf5ea03 --- /dev/null +++ b/docker/watcher/watcher-api/Dockerfile.j2 @@ -0,0 +1,16 @@ +FROM {{ namespace }}/{{ image_prefix }}watcher-base:{{ tag }} +MAINTAINER {{ maintainer }} + +{% if install_type == 'binary' %} + +RUN echo '{{ install_type }} not yet available for {{ base_distro }}' \ + && /bin/false + +{% endif %} + +COPY extend_start.sh /usr/local/bin/kolla_watcher_extend_start +RUN chmod 755 /usr/local/bin/kolla_watcher_extend_start + +{{ include_footer }} + +USER watcher diff --git a/docker/watcher/watcher-api/extend_start.sh b/docker/watcher/watcher-api/extend_start.sh new file mode 100644 index 000000000..d1ea401bb --- /dev/null +++ b/docker/watcher/watcher-api/extend_start.sh @@ -0,0 +1,8 @@ +#!/bin/bash + +# Bootstrap and exit if KOLLA_BOOTSTRAP variable is set. This catches all cases +# of the KOLLA_BOOTSTRAP variable being set, including empty. +if [[ "${!KOLLA_BOOTSTRAP[@]}" ]]; then + watcher-db-manage --config-file /etc/watcher/watcher.conf create_schema + exit 0 +fi |
