2019-03-03 08:50:49 +00:00
|
|
|
# Deploy APT source file:
|
|
|
|
remote_file '/etc/apt/sources.list.d/grafana.list' do
|
|
|
|
owner 'root'
|
|
|
|
group 'root'
|
|
|
|
mode '644'
|
|
|
|
end
|
|
|
|
|
|
|
|
# Load APT key:
|
2019-09-15 14:13:15 +00:00
|
|
|
execute 'curl https://packages.grafana.com/gpg.key | apt-key add -' do
|
|
|
|
not_if 'apt-key list | grep grafana'
|
2019-03-03 08:50:49 +00:00
|
|
|
end
|
|
|
|
|
2022-08-11 03:21:34 +00:00
|
|
|
execute 'apt update' do
|
|
|
|
not_if 'which grafana-server'
|
|
|
|
end
|
2019-03-03 08:50:49 +00:00
|
|
|
|
|
|
|
package 'grafana' do
|
|
|
|
action :install
|
|
|
|
end
|
|
|
|
|