This repository has been archived by the owner on Jul 11, 2020. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b5df487
commit b5cf4d2
Showing
6 changed files
with
10,604 additions
and
3 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
10,572 changes: 10,572 additions & 0 deletions
10,572
cookbooks/rubygems-sensu/files/default/check_postgres.pl
Large diffs are not rendered by default.
Oops, something went wrong.
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 |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# | ||
# Cookbook Name:: rubygems-sensu | ||
# Recipe:: database | ||
# | ||
|
||
sensu_check 'check_postgres_proc' do | ||
command "/opt/sensu/embedded/bin/ruby /etc/sensu/plugins/check-procs.rb -p 'postgres -D'" | ||
handlers ['slack', 'pagerduty'] | ||
subscribers ['database'] | ||
interval 30 | ||
additional(notification: 'postgres is not running', occurences: 3) | ||
end | ||
|
||
sensu_check 'check_postgres_connection' do | ||
command "perl check_postgres.pl --action connection -db rubygems_#{node.chef_environment}" | ||
handlers ['slack', 'pagerduty'] | ||
subscribers ['database'] | ||
interval 30 | ||
additional(occurences: 3) | ||
end | ||
|
||
sensu_check 'check_postgres_backends' do | ||
command "perl check_postgres.pl --action backends -db rubygems_#{node.chef_environment}" | ||
handlers ['slack', 'pagerduty'] | ||
subscribers ['database'] | ||
interval 30 | ||
additional(occurences: 3) | ||
end |
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