Deploy `systemd` config for `filestat_exporter`.

This commit is contained in:
Kazuhiro MUSASHI 2023-02-07 23:02:24 +09:00
parent 448ceda784
commit f6f354115d
2 changed files with 16 additions and 3 deletions

View File

@ -0,0 +1,11 @@
[Unit]
Description=Filestat Exporter
[Service]
User=root
Group=root
ExecStart=/usr/local/bin/filestat_exporter --config.file=/etc/prometheus_exporters.d/filestat.yml
[Install]
WantedBy=multi-user.target

View File

@ -7,13 +7,15 @@ remote_file '/etc/prometheus_exporters.d/filestat.yml' do
notifies :restart, 'service[supervisor]' notifies :restart, 'service[supervisor]'
end end
# Deploy the `supervisord` configuration: # Deploy the `systemd` configuration:
remote_file '/etc/supervisor/conf.d/filestat_exporter.conf' do remote_file '/etc/systemd/system/filestat_exporter.service' do
owner 'root' owner 'root'
group 'root' group 'root'
mode '644' mode '644'
end
notifies :restart, 'service[supervisor]' service 'filestat_exporter' do
action [:enable, :start]
end end
# Deploy `consul` config for `node_exporter`: # Deploy `consul` config for `node_exporter`: