mirror of
https://github.com/famedly/ansible-collection-matrix
synced 2024-12-12 20:22:28 +00:00
make log dir configurable
This commit is contained in:
parent
d6b84e49af
commit
c0ae9920d8
4 changed files with 7 additions and 5 deletions
|
@ -8,6 +8,7 @@ matrix_synapse_dh_path: "{{ matrix_synapse_base_path }}/tls/{{ matrix_server_nam
|
|||
matrix_synapse_baseurl: "https://{{ matrix_server_name }}"
|
||||
matrix_synapse_signing_key_path: "{{ matrix_synapse_base_path }}/tls/{{ matrix_server_name }}.signing.key"
|
||||
matrix_synapse_version: "v0.99.2"
|
||||
matrix_synapse_log_dir: "/var/log/matrix_synapse"
|
||||
matrix_synapse_log_days_keep: 30
|
||||
matrix_synapse_skip_tls: false
|
||||
matrix_synapse_pid_file: "{{ matrix_synapse_base_path }}/synapse.pid"
|
||||
|
|
|
@ -1,2 +0,0 @@
|
|||
if $programname == 'matrix_synapse' then /var/log/matrix_synapse/matrix_synapse.log
|
||||
if $programname == 'matrix_synapse' then ~
|
|
@ -1,14 +1,14 @@
|
|||
---
|
||||
- name: create logging folder
|
||||
file:
|
||||
name: /var/log/synapse/
|
||||
name: "{{ matrix_synapse_log_dir }}"
|
||||
state: directory
|
||||
owner: synapse
|
||||
group: synapse
|
||||
|
||||
- name: copy syslog config
|
||||
copy:
|
||||
src: matrix_synapse.conf
|
||||
template:
|
||||
src: syslog-synapse.conf.j2
|
||||
dest: /etc/rsyslog.d/matrix_synapse.conf
|
||||
owner: root
|
||||
notify: restart rsyslog
|
||||
|
@ -17,6 +17,7 @@
|
|||
template:
|
||||
src: logrotate.j2
|
||||
dest: /etc/logrotate.d/matrix_synapse
|
||||
owner: root
|
||||
|
||||
- name: Deploy log config
|
||||
copy:
|
||||
|
|
2
templates/syslog-synapse.conf.j2
Normal file
2
templates/syslog-synapse.conf.j2
Normal file
|
@ -0,0 +1,2 @@
|
|||
if $programname == 'matrix_synapse' then {{ matrix_synapse_log_dir }}/matrix_synapse.log
|
||||
if $programname == 'matrix_synapse' then ~
|
Loading…
Reference in a new issue