opensearch-dashboards: Fix permissions
Since we moved to using rpm/deb packages, the user has changed.
Related-Bug: #2020152
Change-Id: I2a5a0d761223b4e99c8df59f80261108380d5038
(cherry picked from commit 6786e4384c
)
This commit is contained in:
parent
23e0819d68
commit
7a30d4d768
@ -7,7 +7,7 @@ LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build
|
||||
|
||||
{% import "macros.j2" as macros with context %}
|
||||
|
||||
{{ macros.configure_user(name='opensearch', shell='/bin/bash', homedir='/usr/share/opensearch') }}
|
||||
{{ macros.configure_user(name='opensearch-dashboards', shell='/bin/bash', homedir='/usr/share/opensearch-dashboards') }}
|
||||
{{ macros.enable_extra_repos(['opensearch-dashboards']) }}
|
||||
|
||||
{% set opensearch_dashboards_packages = ['opensearch-dashboards'] %}
|
||||
@ -30,4 +30,4 @@ RUN chmod 755 /usr/local/bin/kolla_extend_start
|
||||
{% block opensearch_footer %}{% endblock %}
|
||||
{% block footer %}{% endblock %}
|
||||
|
||||
USER opensearch
|
||||
USER opensearch-dashboards
|
||||
|
@ -1,10 +1,10 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [[ ! -d "/var/log/kolla/opensearch" ]]; then
|
||||
mkdir -p /var/log/kolla/opensearch
|
||||
if [[ ! -d "/var/log/kolla/opensearch-dashboards" ]]; then
|
||||
mkdir -p /var/log/kolla/opensearch-dashboards
|
||||
fi
|
||||
if [[ $(stat -c %a /var/log/kolla/opensearch) != "755" ]]; then
|
||||
chmod 755 /var/log/kolla/opensearch
|
||||
if [[ $(stat -c %a /var/log/kolla/opensearch-dashboards) != "755" ]]; then
|
||||
chmod 755 /var/log/kolla/opensearch-dashboards
|
||||
fi
|
||||
|
||||
export DASHBOARDS_HOME=/usr/share/opensearch-dashboards
|
||||
|
@ -960,6 +960,10 @@ USERS = {
|
||||
'opensearch-user': {
|
||||
'uid': 42490,
|
||||
'gid': 42490,
|
||||
},
|
||||
'opensearch-dashboards-user': {
|
||||
'uid': 42492,
|
||||
'gid': 42492,
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user