Deploy the alert settings.

This commit is contained in:
Kazuhiro MUSASHI 2020-07-19 01:06:26 +09:00
parent 568bcf0538
commit c969038bdc
1 changed files with 7 additions and 5 deletions

View File

@ -17,13 +17,15 @@ remote_file '/etc/prometheus.d/alertmanager.yml' do
end
# Deploy alert setting file:
remote_file '/etc/prometheus.d/alerts/resource.yml' do
%w(node_exporter prometheus).each do |conf|
remote_file "/etc/prometheus.d/alerts/#{conf}.yml" do
owner 'root'
group 'root'
mode '644'
notifies :restart, 'service[supervisor]'
end
end
# Restart the `supervisor`:
service 'supervisor' do