Fix potential Monasca-thresh start failure
Monasca-thresh inherits from the Storm container, but we want it to write logs to the Monasca logs directory. In this commit we overwrite the script which configures the Storm log directory with the Monasca script. Change-Id: Id961134e424117ebefb088021faaf37fa02757d7 Partially-Implements: blueprint monasca-containers
This commit is contained in:
parent
2743931fe3
commit
a13b4fbfcf
@ -64,6 +64,11 @@ RUN cd /monasca-common-source/java \
|
||||
|
||||
{% endif %}
|
||||
|
||||
# Overwrite the script inherited from Storm
|
||||
COPY extend_start.sh /usr/local/bin/kolla_extend_start
|
||||
RUN touch /usr/local/bin/kolla_monasca_extend_start \
|
||||
&& chmod 755 /usr/local/bin/kolla_extend_start /usr/local/bin/kolla_monasca_extend_start
|
||||
|
||||
{% block monasca_thresh_footer %}{% endblock %}
|
||||
{% block footer %}{% endblock %}
|
||||
|
||||
|
15
docker/monasca/monasca-thresh/extend_start.sh
Normal file
15
docker/monasca/monasca-thresh/extend_start.sh
Normal file
@ -0,0 +1,15 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Create log directory, with appropriate permissions
|
||||
MONASCA_LOG_DIR="/var/log/kolla/monasca"
|
||||
if [[ ! -d "$MONASCA_LOG_DIR" ]]; then
|
||||
mkdir -p $MONASCA_LOG_DIR
|
||||
fi
|
||||
if [[ $(stat -c %U:%G ${MONASCA_LOG_DIR}) != "monasca:kolla" ]]; then
|
||||
chown monasca:kolla ${MONASCA_LOG_DIR}
|
||||
fi
|
||||
if [[ $(stat -c %a ${MONASCA_LOG_DIR}) != "755" ]]; then
|
||||
chmod 755 ${MONASCA_LOG_DIR}
|
||||
fi
|
||||
|
||||
. /usr/local/bin/kolla_monasca_extend_start
|
Loading…
Reference in New Issue
Block a user