diff options
| author | Éric Lemoine <elemoine@mirantis.com> | 2016-02-17 14:26:19 +0100 |
|---|---|---|
| committer | SamYaple <sam@yaple.net> | 2016-02-19 21:56:10 +0000 |
| commit | 82264ab7d6d178b6d69c84016997cd4df34f112a (patch) | |
| tree | 65eae718c9fab9fea60dd0e9356da3617e9b0bf0 /docker/heat | |
| parent | 170b493d472be4c4e44f5a94a8e4a774a37e198c (diff) | |
| download | kolla-82264ab7d6d178b6d69c84016997cd4df34f112a.tar.gz kolla-82264ab7d6d178b6d69c84016997cd4df34f112a.zip | |
Make Heka collect Heat logs
Partially implements: blueprint heka
Change-Id: Ie22c4326c6ec2a3426b0c3b8fda4554b1b2541b0
Diffstat (limited to 'docker/heat')
| -rw-r--r-- | docker/heat/heat-api/extend_start.sh | 7 | ||||
| -rw-r--r-- | docker/heat/heat-base/Dockerfile.j2 | 9 | ||||
| -rw-r--r-- | docker/heat/heat-base/extend_start.sh | 8 |
3 files changed, 21 insertions, 3 deletions
diff --git a/docker/heat/heat-api/extend_start.sh b/docker/heat/heat-api/extend_start.sh index ca4f83da5..2eb7468f5 100644 --- a/docker/heat/heat-api/extend_start.sh +++ b/docker/heat/heat-api/extend_start.sh @@ -1,5 +1,12 @@ #!/bin/bash +if [[ ! -d "/var/log/kolla/heat" ]]; then + mkdir -p /var/log/kolla/heat +fi +if [[ $(stat -c %a /var/log/kolla/heat) != "755" ]]; then + chmod 755 /var/log/kolla/heat +fi + # 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 diff --git a/docker/heat/heat-base/Dockerfile.j2 b/docker/heat/heat-base/Dockerfile.j2 index ca818b94b..bbdce7e90 100644 --- a/docker/heat/heat-base/Dockerfile.j2 +++ b/docker/heat/heat-base/Dockerfile.j2 @@ -21,10 +21,13 @@ ADD heat-base-archive /heat-base-source RUN ln -s heat-base-source/* heat \ && useradd --user-group heat \ && /var/lib/kolla/venv/bin/pip --no-cache-dir install --upgrade -c requirements/upper-constraints.txt /heat \ - && mkdir -p /etc/heat /var/log/heat /home/heat \ + && mkdir -p /etc/heat /home/heat \ && cp -r /heat/etc/heat/* /etc/heat/ \ - && chown -R heat: /etc/heat /var/log/heat /home/heat + && chown -R heat: /etc/heat /home/heat {% endif %} -RUN usermod -a -G kolla heat +COPY extend_start.sh /usr/local/bin/kolla_extend_start + +RUN usermod -a -G kolla heat \ + && chmod 755 /usr/local/bin/kolla_extend_start diff --git a/docker/heat/heat-base/extend_start.sh b/docker/heat/heat-base/extend_start.sh new file mode 100644 index 000000000..9cdefa6ad --- /dev/null +++ b/docker/heat/heat-base/extend_start.sh @@ -0,0 +1,8 @@ +#!/bin/bash + +if [[ ! -d "/var/log/kolla/heat" ]]; then + mkdir -p /var/log/kolla/heat +fi +if [[ $(stat -c %a /var/log/kolla/heat) != "755" ]]; then + chmod 755 /var/log/kolla/heat +fi |
