-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #70 from puppetlabs-seteam/maju6406sensu
Adding optional sensu monitoring to tse-control repo
- Loading branch information
Showing
29 changed files
with
756 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,64 @@ | ||
--- | ||
puppet_enterprise::profile::master::check_for_updates: false | ||
|
||
# flag for enabling general sensu monitoring for the node | ||
profile::platform::baseline::enable_monitoring: false | ||
|
||
# flag for enabling webserver monitoring via sensu | ||
profile::app::sample_website::linux::enable_monitoring: false | ||
profile::app::sample_website::windows::enable_monitoring: false | ||
|
||
profile::app::redis::bind: '127.0.0.1' | ||
|
||
profile::app::sensu::server::rabbitmq_host: '127.0.0.1' | ||
profile::app::sensu::server::rabbitmq_user: 'admin' | ||
profile::app::sensu::server::rabbitmq_password: 'puppetlabs' | ||
profile::app::sensu::server::rabbitmq_vhost: '/sensu' | ||
profile::app::sensu::server::subscriptions: | ||
- "all" | ||
- "sensu-server" | ||
- "%{::kernel}" | ||
|
||
profile::app::sensu::client::rabbitmq_host: 'sensu-server.pdx.puppet.vm' | ||
profile::app::sensu::client::rabbitmq_user: "%{alias('profile::app::sensu::server::rabbitmq_user')}" | ||
profile::app::sensu::client::rabbitmq_password: "%{alias('profile::app::sensu::server::rabbitmq_password')}" | ||
profile::app::sensu::client::rabbitmq_vhost: "%{alias('profile::app::sensu::server::rabbitmq_vhost')}" | ||
profile::app::sensu::client::subscriptions: | ||
- "all" | ||
- "%{::kernel}" | ||
|
||
profile::app::sensu::handlers::mailer_from: '[email protected]' | ||
profile::app::sensu::handlers::mailer_to: | ||
- '[email protected]' | ||
|
||
profile::app::sensu::handlers::hipchat_url: 'https://api.hipchat.com' | ||
profile::app::sensu::handlers::hipchat_apikey: 'tb1mz4vQR0SGBlrAdaUkOOzWE9aFqCChHhTwISqh' | ||
profile::app::sensu::handlers::hipchat_room: 'seteam notification sandbox' | ||
profile::app::sensu::handlers::hipchat_from: 'beersy' | ||
profile::app::sensu::handlers::hipchat_message_template: | | ||
<%= | ||
[ | ||
"<b>Sensu:</b> #{@event['client']['name']} ", | ||
@event["action"].eql?("resolve") ? "RESOLVED" : "ALERT", | ||
"<br><b>event</b> - [#{event_name}]<br>", | ||
"<b>command</b>: #{@event['check']['command']}<br>", | ||
"<b>occurrences</b>: #{@event['occurrences']}<br><b>Output:</b>", | ||
@event["check"]["notification"] || @event["check"]["output"], | ||
"<br>", | ||
playbook, | ||
].join | ||
%> | ||
|
||
profile::app::sensu::plugins::plugin_list: | ||
- 'sensu-plugins-http' | ||
- 'sensu-plugins-rabbitmq' | ||
- 'sensu-plugins-redis' | ||
- 'sensu-plugins-disk-checks' | ||
- 'sensu-plugins-load-checks' | ||
- 'sensu-plugins-memory-checks' | ||
- 'sensu-plugins-process-checks' | ||
- 'sensu-plugins-hardware' | ||
- 'sensu-plugins-ntp' | ||
- 'sensu-plugins-mailer' | ||
- 'sensu-plugins-dns' | ||
- 'sensu-plugins-hipchat' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,68 @@ | ||
body { | ||
margin-top: 200px; | ||
margin-left: 60px; | ||
width: 70%; | ||
font-family: 'Helvetica', 'Arial', 'Sans-Serif'; | ||
background:black url(../img/logo.png) no-repeat left top; | ||
} | ||
|
||
a { text-decoration: none; color: #999; } | ||
a:hover { text-decoration: underline; } | ||
|
||
p, ul { font-size: 1.5em; line-height: 0.5em; color: #fff; } | ||
|
||
h1, h2, h3, h4 { color: #ffad1a } | ||
h1 { font-size: 2em; } | ||
h2 { font-size: 1.7em; } | ||
h3 { font-size: 1.5em; } | ||
h4 { font-size: 1.3em; } | ||
|
||
nav ul, footer ul { padding: 0px; list-style: none; font-weight: bold; } | ||
nav ul li, footer ul li { display: inline; margin-right: 20px; } | ||
|
||
footer { border-top: 1px solid #d5d5d5; font-size: .8em; } | ||
body { | ||
margin-top: 200px; | ||
margin-left: 60px; | ||
width: 70%; | ||
font-family: 'Helvetica', 'Arial', 'Sans-Serif'; | ||
background: black url(../img/logo.png) no-repeat left top; | ||
} | ||
|
||
a { | ||
text-decoration: none; | ||
color: #999; | ||
} | ||
|
||
a:hover { | ||
text-decoration: underline; | ||
} | ||
|
||
p, | ||
ul { | ||
font-size: 1.5em; | ||
line-height: 0.5em; | ||
color: #fff; | ||
} | ||
|
||
h1, | ||
h2, | ||
h3, | ||
h4 { | ||
color: #ffad1a | ||
} | ||
|
||
h1.error { | ||
color: #ff0000; | ||
} | ||
|
||
h1 { | ||
font-size: 2em; | ||
} | ||
|
||
h2 { | ||
font-size: 1.7em; | ||
} | ||
|
||
h3 { | ||
font-size: 1.5em; | ||
} | ||
|
||
h4 { | ||
font-size: 1.3em; | ||
} | ||
|
||
nav ul, | ||
footer ul { | ||
padding: 0px; | ||
list-style: none; | ||
font-weight: bold; | ||
} | ||
|
||
nav ul li, | ||
footer ul li { | ||
display: inline; | ||
margin-right: 20px; | ||
} | ||
|
||
footer { | ||
border-top: 1px solid #d5d5d5; | ||
font-size: .8em; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
# install rabbitmq | ||
class profile::app::rabbitmq { | ||
|
||
include packagecloud | ||
packagecloud::repo { 'rabbitmq/rabbitmq-server': | ||
type => 'rpm', | ||
require => Class['packagecloud'] | ||
} | ||
|
||
packagecloud::repo { 'rabbitmq/erlang': | ||
type => 'rpm', | ||
require => Class['packagecloud'] | ||
} | ||
|
||
class { 'rabbitmq': | ||
package_ensure => 'latest', | ||
repos_ensure => true, | ||
require => [ | ||
Class['packagecloud'], | ||
Package['erlang'], | ||
], | ||
} | ||
|
||
package { 'erlang': | ||
ensure => 'latest', | ||
require => Packagecloud::Repo['rabbitmq/erlang'] | ||
} | ||
|
||
firewall { '5672 allow rabbitmq access': | ||
dport => '5672', | ||
proto => tcp, | ||
action => accept, | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
# install redis | ||
class profile::app::redis ( | ||
String $bind, | ||
){ | ||
require epel | ||
class { 'redis': | ||
bind => $bind, | ||
require => Class['::epel'] | ||
} | ||
|
||
firewall { '6379 allow redis access': | ||
dport => '6379', | ||
proto => tcp, | ||
action => accept, | ||
} | ||
} |
Oops, something went wrong.