Skip to content

Commit

Permalink
Update Grafana to 1.8.0-rc1, add new configs for window_title_prefix …
Browse files Browse the repository at this point in the history
…and search_max_results¬
  • Loading branch information
JonathanTron committed Sep 12, 2014
1 parent e71dcbe commit 8c84a81
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 4 deletions.
10 changes: 9 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,15 @@

This file is used to list changes made in each version of grafana.

## 1.3.5 (dev):
## 1.4.0:

* Update `Grafana` to `1.8.0-rc1`
* Add `default['grafana']['window_title_prefix']` and
`default['grafana']['search_max_results']` config attributes.

__warnings__

* `Grafana 1.8.0-rc1` upgraded to `JQuery` to `2.1.1` and thus dropped support for `Internet Explorer 7 and 8`

## 1.3.4:

Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ As with most cookbooks I write, this one is hopefully flexible enough to be wrap
| `node['grafana']['grafana_index']` | `'grafana-index'` | Elasticsearch index to use for Grafana |
| `node['grafana']['unsaved_changes_warning']` | `'true'` | Enable disable unsaved changes warning in UI |
| `node['grafana']['playlist_timespan']` | `'1m'` | Playlist timespan config |
| `node['grafana']['window_title_prefix']` | `'Grafana - '` | Window title prefix config |
| `node['grafana']['search_max_results']` | `20` | Search maximuyum result config |
| `node['grafana']['datasources']` | see below | Grafana (`> 1.7.0`) data sources configuration |

Starting with `1.7.0`, Grafana uses `datasources` array in its configuration file
Expand Down
6 changes: 4 additions & 2 deletions attributes/default.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
default['grafana']['git']['branch'] = 'master'
default['grafana']['git']['type'] = 'sync' # checkout | sync
default['grafana']['file']['type'] = 'tar.gz' # tar.gz | zip
default['grafana']['file']['version'] = '1.7.0'
default['grafana']['file']['version'] = '1.8.0-rc1'
f = node['grafana']['file']
default['grafana']['file']['url'] = "http://grafanarel.s3.amazonaws.com/grafana-#{f['version']}.#{f['type']}"
default['grafana']['file']['checksum'] = '6da4c234677ffe7ebb1268fa46a9c03921478c789eb600774575b1629793ef57' # sha256 ( shasum -a 256 FILENAME )
default['grafana']['file']['checksum'] = '984a6f79a930b87d9132ab1f77be5d6efb8d91181c8b29c1e45383cb04e05650' # sha256 ( shasum -a 256 FILENAME )
default['grafana']['webserver'] = 'nginx'
default['grafana']['install_path'] = '/srv/apps'
default['grafana']['install_dir'] = "#{node['grafana']['install_path']}/grafana"
Expand Down Expand Up @@ -49,6 +49,8 @@
default['grafana']['grafana_index'] = 'grafana-index'
default['grafana']['unsaved_changes_warning'] = 'true'
default['grafana']['playlist_timespan'] = '1m'
default['grafana']['window_title_prefix'] = 'Grafana - '
default['grafana']['search_max_results'] = 20
default['grafana']['datasources'] = {
'graphite' => {
'type' => "'graphite'",
Expand Down
2 changes: 1 addition & 1 deletion metadata.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
license 'Apache 2.0'
description 'Installs/Configures grafana'
long_description IO.read(File.join(File.dirname(__FILE__), 'README.md'))
version '1.3.5'
version '1.4.0'

depends 'git'
depends 'ark', '>= 0.7.2'
Expand Down
8 changes: 8 additions & 0 deletions templates/default/config.js.erb
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,14 @@ function (Settings) {
// Example: "1m", "1h"
playlist_timespan: "<%= node['grafana']['playlist_timespan'] %>",
// Change window title prefix from 'Grafana - <dashboard title>'
window_title_prefix: "<%= node['grafana']['window_title_prefix'] %>",
// specify the limit for dashboard search results
search: {
max_results: <%= node['grafana']['search_max_results'] %>
},

// Add your own custom pannels
plugins: {
panels: []
Expand Down

0 comments on commit 8c84a81

Please sign in to comment.