Dzahn has uploaded a new change for review.
https://gerrit.wikimedia.org/r/249060
Change subject: logstash: fix double quoted strings
......................................................................
logstash: fix double quoted strings
Change-Id: I22b7d6976006bc0233766435207cb50db7bee8e9
---
M manifests/role/logstash.pp
1 file changed, 27 insertions(+), 71 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/operations/puppet
refs/changes/60/249060/1
diff --git a/manifests/role/logstash.pp b/manifests/role/logstash.pp
index 19d5453..e57b779 100644
--- a/manifests/role/logstash.pp
+++ b/manifests/role/logstash.pp
@@ -25,39 +25,39 @@
port => 8324,
}
- ferm::service { "logstash_udp2log":
- proto => 'udp',
- port => '8324',
+ ferm::service { 'logstash_udp2log':
+ proto => 'udp',
+ port => '8324',
notrack => true,
- srange => '$ALL_NETWORKS',
+ srange => '$ALL_NETWORKS',
}
logstash::input::syslog { 'syslog':
port => 10514,
}
- ferm::service { "logstash_syslog":
- proto => 'udp',
- port => '10514',
+ ferm::service { 'logstash_syslog':
+ proto => 'udp',
+ port => '10514',
notrack => true,
- srange => '$ALL_NETWORKS',
+ srange => '$ALL_NETWORKS',
}
- ferm::service { "grafana_dashboard_definition_storage":
+ ferm::service { 'grafana_dashboard_definition_storage':
proto => 'tcp',
port => '9200',
- srange => '@resolve(krypton.eqiad.wmnet)',
+ srange => '$INTERNAL',
}
logstash::input::gelf { 'gelf':
port => 12201,
}
- ferm::service { "logstash_gelf":
- proto => 'udp',
- port => '12201',
+ ferm::service { 'logstash_gelf':
+ proto => 'udp',
+ port => '12201',
notrack => true,
- srange => '$ALL_NETWORKS',
+ srange => '$ALL_NETWORKS',
}
logstash::input::udp { 'logback':
@@ -65,11 +65,11 @@
codec => 'json',
}
- ferm::service { "logstash_udp":
- proto => 'udp',
- port => '11514',
+ ferm::service { 'logstash_udp':
+ proto => 'udp',
+ port => '11514',
notrack => true,
- srange => '$ALL_NETWORKS',
+ srange => '$ALL_NETWORKS',
}
## Global pre-processing (15)
@@ -147,28 +147,15 @@
increment => [ '%{channel}.%{level}' ],
}
- logstash::output::statsd { 'OOM_channel_rate':
- host => $statsd_host,
- guard_condition => '[type] == "hhvm" and [message] =~ "request has
exceeded memory limit"',
- namespace => 'logstash.rate',
- sender => 'oom',
- increment => [ '%{level}' ],
- }
+ ## Firewalling
+ $logstash_nodes = hiera('logstash::cluster_hosts')
+ $logstash_nodes_ferm = join($logstash_nodes, ' ')
- logstash::output::statsd { 'HHVM_channel_rate':
- host => $statsd_host,
- guard_condition => '[type] == "hhvm" and [message] !~ "request has
exceeded memory limit"',
- namespace => 'logstash.rate',
- sender => 'hhvm',
- increment => [ '%{level}' ],
- }
-
- logstash::output::statsd { 'Apache2_channel_rate':
- host => $statsd_host,
- guard_condition => '[type] == "apache2" and "syslog" in [tags]',
- namespace => 'logstash.rate',
- sender => 'apache2',
- increment => [ '%{level}' ],
+ ferm::service { 'logstash_elastic_internode':
+ proto => 'tcp',
+ port => 9300,
+ notrack => true,
+ srange => "@resolve((${logstash_nodes_ferm}))",
}
}
@@ -190,16 +177,6 @@
class { '::elasticsearch':
require => Package['elasticsearch/plugins'],
- }
-
- $logstash_nodes = hiera('logstash::cluster_hosts')
- $logstash_nodes_ferm = join($logstash_nodes, ' ')
-
- ferm::service { 'logstash_elastic_internode':
- proto => 'tcp',
- port => 9300,
- notrack => true,
- srange => "@resolve((${logstash_nodes_ferm}))",
}
}
@@ -342,7 +319,7 @@
}
logstash::output::elasticsearch { 'logstash':
host => '127.0.0.1',
- index => "logstash-%{+YYYY.MM}",
+ index => 'logstash-%{+YYYY.MM}',
guard_condition => '"es" in [tags]',
priority => 90,
template => '/etc/logstash/stashbot-template.json',
@@ -384,24 +361,3 @@
}
}
-# == Class: role::logstash::eventlogging
-#
-# Configure Logstash to consume validation logs from EventLogging.
-#
-class role::logstash::eventlogging {
- include ::role::logstash
- include ::role::analytics::kafka::config
-
- $topic = 'eventlogging_EventError'
-
- logstash::input::kafka { $topic:
- tags => [$topic, 'kafka'],
- type => 'eventlogging',
- zk_connect => $role::analytics::kafka::config::zookeeper_url,
- }
-
- logstash::conf { 'filter_eventlogging':
- source => 'puppet:///files/logstash/filter-eventlogging.conf',
- priority => 50,
- }
-}
--
To view, visit https://gerrit.wikimedia.org/r/249060
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I22b7d6976006bc0233766435207cb50db7bee8e9
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Dzahn <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits