kolla-ansible/ansible/roles/placement/templates/placement-api.json.j2
Michal Nasiadka 367ca93564 Fix placement log perms in config.json
Currently placement-api is configured to log to
/var/log/kolla/placement/placement-api.log, but config.json is changing
permissions of /var/log/kolla/placement/placement.log - this patch
changes this.

Change-Id: I7f1591bdbc7c03302befc3ca6ebf1b13c95640c2
(cherry picked from commit b850eeec9c)
2019-06-18 18:31:41 +00:00

43 lines
1.5 KiB
Django/Jinja

{% set apache_binary = 'apache2' if kolla_base_distro in ['ubuntu', 'debian'] else 'httpd' %}
{% set apache_conf_dir = 'apache2/conf-enabled' if kolla_base_distro in ['ubuntu', 'debian'] else 'httpd/conf.d' %}
{
"command": "/usr/sbin/{{ apache_binary }} -DFOREGROUND",
"config_files": [
{
"source": "{{ container_config_directory }}/placement.conf",
"dest": "/etc/placement/placement.conf",
"owner": "placement",
"perm": "0600"
}{% if placement_policy_file is defined %},
{
"source": "{{ container_config_directory }}/{{ placement_policy_file }}",
"dest": "/etc/placement/{{ placement_policy_file }}",
"owner": "placement",
"perm": "0600"
}{% endif %},
{
"source": "{{ container_config_directory }}/placement-api-wsgi.conf",
"dest": "/etc/{{ apache_conf_dir }}/00-placement-api.conf",
"owner": "placement",
"perm": "0600"
},
{
"source": "{{ container_config_directory }}/migrate-db.rc",
"dest": "/etc/placement/migrate-db.rc",
"owner": "placement",
"perm": "0600"
}
],
"permissions": [
{
"path": "/var/log/kolla/placement",
"owner": "placement:kolla",
"recurse": true
},
{
"path": "/var/log/kolla/placement/placement-api.log",
"owner": "placement:placement"
}
]
}