From ff1daa0173e7ee782205f5c1f9626efd0cc79a9a Mon Sep 17 00:00:00 2001 From: Will Bradley Date: Tue, 19 Nov 2013 06:41:42 +0000 Subject: [PATCH] Adding looser/more logstash sources, and fixing a git error with older versions of ansible --- files/logstash/logstash.conf | 14 +++++++++----- tasks/kibana-setup.yml | 4 +++- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/files/logstash/logstash.conf b/files/logstash/logstash.conf index a72fe9d..b2df371 100644 --- a/files/logstash/logstash.conf +++ b/files/logstash/logstash.conf @@ -8,13 +8,17 @@ input { port => 5514 type => "linux-syslog" } -} -filter { - grok { - type => "linux-syslog" - pattern => "%{SYSLOGLINE}" + file { + type => "syslog" + path => [ "/var/log/*.log", "/var/log/messages", "/var/log/syslog", "/var/log/nginx/*.log" ] } } +#filter { +# grok { +# type => "linux-syslog" +# pattern => "%{SYSLOGLINE}" +# } +#} # Define outputs output { # send events to stdout for easy debugging diff --git a/tasks/kibana-setup.yml b/tasks/kibana-setup.yml index a690823..0803437 100644 --- a/tasks/kibana-setup.yml +++ b/tasks/kibana-setup.yml @@ -10,9 +10,11 @@ - nginx - name: ensure we have the specified logstash release - git: repo=https://github.com/elasticsearch/kibana.git dest=/var/www/kibana update=yes + git: repo=https://github.com/elasticsearch/kibana.git dest=/var/www/kibana #update=yes - name: ensure kibana nginx site is in place template: src=../files/kibana/kibana.conf.j2 dest=/etc/nginx/sites-available/kibana mode=0755 +- name: ensure kibana is secured with a password + template: src=../files/kibana/kibana.htpasswd.j2 dest=/etc/nginx/conf.d/kibana.htpasswd mode=0755 - name: ensure default Nginx site is not enabled file: state=absent path=/etc/nginx/sites-enabled/default - name: ensure kibana nginx site is enabled