From 46b1b91607f35135d344d668cb77321b359e9cac Mon Sep 17 00:00:00 2001 From: zhubingbing Date: Tue, 1 Aug 2017 13:23:22 -0400 Subject: [PATCH] Add panko log in fluentd Change-Id: Ic3b994056e6287488a0a9f7dbeb140c007ad86d3 --- .../roles/common/templates/conf/filter/01-rewrite.conf.j2 | 3 ++- ansible/roles/panko/templates/panko.conf.j2 | 6 ++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/ansible/roles/common/templates/conf/filter/01-rewrite.conf.j2 b/ansible/roles/common/templates/conf/filter/01-rewrite.conf.j2 index e76038a070..2ca4ab71c0 100644 --- a/ansible/roles/common/templates/conf/filter/01-rewrite.conf.j2 +++ b/ansible/roles/common/templates/conf/filter/01-rewrite.conf.j2 @@ -1,7 +1,7 @@ @type rewrite_tag_filter capitalize_regex_backreference yes - rewriterule1 programname ^(cinder-api-access|gnocchi-api-access|horizon-access|keystone-apache-admin-access|keystone-apache-public-access|placement-api-access)$ apache_access + rewriterule1 programname ^(cinder-api-access|gnocchi-api-access|horizon-access|keystone-apache-admin-access|keystone-apache-public-access|placement-api-access|panko-api-access)$ apache_access rewriterule2 programname ^(aodh_wsgi_access | zun_api_wsgi_access)$ wsgi_access rewriterule3 programname ^(nova-api|nova-compute|nova-conductor|nova-consoleauth|nova-manage|nova-novncproxy|nova-scheduler|nova-placement-api|placement-api|privsep-helper)$ openstack_python rewriterule4 programname ^(sahara-api|sahara-engine)$ openstack_python @@ -29,4 +29,5 @@ rewriterule26 programname ^(kuryr-server)$ openstack_python rewriterule27 programname ^(gnocchi-api|gnocchi-statsd|gnocchi-metricd|gnocchi-upgrade)$ openstack_python rewriterule28 programname ^(ironic-api|ironic-conductor)$ openstack_python + rewriterule29 programname ^(panko-api|panko-dbsync)$ openstack_python diff --git a/ansible/roles/panko/templates/panko.conf.j2 b/ansible/roles/panko/templates/panko.conf.j2 index b6d0643b02..c923e32040 100644 --- a/ansible/roles/panko/templates/panko.conf.j2 +++ b/ansible/roles/panko/templates/panko.conf.j2 @@ -3,6 +3,12 @@ log_dir = /var/log/kolla/panko debug = {{ panko_logging_debug }} +{% if service_name == 'panko-api' %} +# Force panko-api.log or will use app.wsgi +log_file = /var/log/kolla/panko/panko-api.log +{% endif %} + + [database] {% if panko_database_type == "mongodb" %} event_connection = mongodb://{{ panko_database_user }}:{{ panko_database_password }}@{{ panko_database_mongodb_address }}/{{ panko_database_name }}