Use systemd-journald instead of log files

This patch aims to migrate service from usage of regular syslog files
to journald. We also disable uwsgi logging, since it dublicates
requests that are logged by service itself.

Change-Id: I61605b7820bb518fb809b01781f6d83f89487be8
This commit is contained in:
Dmitriy Rabotyagov 2019-07-17 19:01:17 +03:00 committed by Dmitriy Rabotyagov (noonedeadpunk)
parent 1516054746
commit c9e5f629b4
7 changed files with 9 additions and 4 deletions

View File

@ -43,6 +43,7 @@ mistral_pip_packages:
- mistral - mistral
- PyMySQL - PyMySQL
- python-memcached - python-memcached
- systemd-python
- uwsgi - uwsgi
mistral_optional_oslomsg_amqp1_pip_packages: mistral_optional_oslomsg_amqp1_pip_packages:
- oslo.messaging[amqp1] - oslo.messaging[amqp1]

View File

@ -56,8 +56,6 @@
- path: "/etc/mistral" - path: "/etc/mistral"
mode: "0750" mode: "0750"
- path: "{{ mistral_system_user_home }}" - path: "{{ mistral_system_user_home }}"
- path: "/var/log/mistral"
mode: "0755"
- name: Install distro packages - name: Install distro packages
package: package:

View File

@ -22,7 +22,7 @@ lazy-apps = true
add-header = Connection: close add-header = Connection: close
buffer-size = {{ mistral_wsgi_buffer_size }} buffer-size = {{ mistral_wsgi_buffer_size }}
thunder-lock = true thunder-lock = true
logfile-chmod = 644 disable-logging = true
pidfile = /var/run/{{ item.service_name }}/{{ item.service_name }}.pid pidfile = /var/run/{{ item.service_name }}/{{ item.service_name }}.pid
# Avoid filling up the logs with health check requests from haproxy. # Avoid filling up the logs with health check requests from haproxy.

View File

@ -2,7 +2,7 @@
[DEFAULT] [DEFAULT]
debug = {{ mistral_debug }} debug = {{ mistral_debug }}
log_dir = /var/log/mistral use_journal = True
transport_url = {{ mistral_oslomsg_rpc_transport }}://{% for host in mistral_oslomsg_rpc_servers.split(',') %}{{ mistral_oslomsg_rpc_userid }}:{{ mistral_oslomsg_rpc_password }}@{{ host }}:{{ mistral_oslomsg_rpc_port }}{% if not loop.last %},{% else %}/{{ mistral_oslomsg_rpc_vhost }}{% if mistral_oslomsg_rpc_use_ssl | bool %}?ssl=1{% else %}?ssl=0{% endif %}{% endif %}{% endfor %} transport_url = {{ mistral_oslomsg_rpc_transport }}://{% for host in mistral_oslomsg_rpc_servers.split(',') %}{{ mistral_oslomsg_rpc_userid }}:{{ mistral_oslomsg_rpc_password }}@{{ host }}:{{ mistral_oslomsg_rpc_port }}{% if not loop.last %},{% else %}/{{ mistral_oslomsg_rpc_vhost }}{% if mistral_oslomsg_rpc_use_ssl | bool %}?ssl=1{% else %}?ssl=0{% endif %}{% endif %}{% endfor %}
[api] [api]

View File

@ -15,6 +15,7 @@
mistral_devel_distro_packages: mistral_devel_distro_packages:
- git-core - git-core
- libsystemd-dev
mistral_distro_packages: mistral_distro_packages:
- libxml2 - libxml2
@ -22,6 +23,7 @@ mistral_distro_packages:
mistral_service_distro_packages: mistral_service_distro_packages:
- python3-mistral - python3-mistral
- python3-systemd
- uwsgi - uwsgi
- uwsgi-plugin-python3 - uwsgi-plugin-python3

View File

@ -15,6 +15,7 @@
mistral_devel_distro_packages: mistral_devel_distro_packages:
- git - git
- systemd-devel
mistral_distro_packages: [] mistral_distro_packages: []
@ -23,6 +24,7 @@ mistral_service_distro_packages:
- openstack-mistral-engine - openstack-mistral-engine
- openstack-mistral-executor - openstack-mistral-executor
- openstack-mistral-notifier - openstack-mistral-notifier
- systemd-python
mistral_oslomsg_amqp1_distro_packages: mistral_oslomsg_amqp1_distro_packages:
- cyrus-sasl-lib - cyrus-sasl-lib

View File

@ -15,11 +15,13 @@
mistral_devel_distro_packages: mistral_devel_distro_packages:
- git - git
- systemd-devel
mistral_distro_packages: [] mistral_distro_packages: []
mistral_service_distro_packages: mistral_service_distro_packages:
- openstack-mistral - openstack-mistral
- python-systemd
mistral_oslomsg_amqp1_distro_packages: mistral_oslomsg_amqp1_distro_packages:
- cyrus-sasl - cyrus-sasl