logging config
This commit is contained in:
parent
3ad0db6973
commit
62687973fc
3 changed files with 22 additions and 2 deletions
|
@ -67,6 +67,13 @@
|
||||||
shell:
|
shell:
|
||||||
cmd: "{{ nextcloud_elasticsearch_bin_dir }}/elasticsearch-plugin install --batch ingest-attachment"
|
cmd: "{{ nextcloud_elasticsearch_bin_dir }}/elasticsearch-plugin install --batch ingest-attachment"
|
||||||
|
|
||||||
|
- name: Set elasticsearch logrotate config
|
||||||
|
template:
|
||||||
|
src: elasticsearch-logrotate.j2
|
||||||
|
dest: /etc/logrotate.d/elasticsearch
|
||||||
|
owner: root
|
||||||
|
group: root
|
||||||
|
|
||||||
- name: Restart elasticsearch
|
- name: Restart elasticsearch
|
||||||
service:
|
service:
|
||||||
name: elasticsearch
|
name: elasticsearch
|
||||||
|
@ -74,7 +81,7 @@
|
||||||
enabled: yes
|
enabled: yes
|
||||||
daemon_reload: yes
|
daemon_reload: yes
|
||||||
|
|
||||||
- name: Set live-index serice file
|
- name: Set live-index service file
|
||||||
template:
|
template:
|
||||||
src: nextcloud-fulltextsearch-live-index.service.j2
|
src: nextcloud-fulltextsearch-live-index.service.j2
|
||||||
dest: /etc/systemd/system/nextcloud-fulltextsearch-live-index.service
|
dest: /etc/systemd/system/nextcloud-fulltextsearch-live-index.service
|
||||||
|
|
10
templates/elasticsearch-logrotate.j2
Normal file
10
templates/elasticsearch-logrotate.j2
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
/var/log/elasticsearch/elasticsearch.log {
|
||||||
|
daily
|
||||||
|
missingok
|
||||||
|
rotate 30
|
||||||
|
compress
|
||||||
|
delaycompress
|
||||||
|
notifempty
|
||||||
|
create 640 elasticsearch elasticsearch
|
||||||
|
su root elasticsearch
|
||||||
|
}
|
|
@ -85,4 +85,7 @@ http.port: {{ elasticsearch_nextcloud_port }}
|
||||||
#
|
#
|
||||||
# Require explicit names when deleting indices:
|
# Require explicit names when deleting indices:
|
||||||
#
|
#
|
||||||
#action.destructive_requires_name: true
|
#action.destructive_requires_name: true
|
||||||
|
|
||||||
|
# Log level
|
||||||
|
logger.org.elasticsearch.transport: ERROR
|
Loading…
Add table
Add a link
Reference in a new issue