Skip to content

Commit

Permalink
Merge pull request #1 from PagerTree/grafana-5.4.2
Browse files Browse the repository at this point in the history
Moves to Grafana 5.4.2
  • Loading branch information
armiiller authored Jan 3, 2019
2 parents 4e3fb22 + 89a1ace commit 16bf3fb
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 18 deletions.
15 changes: 0 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,21 +58,6 @@ Here's a list of all the services that are created:

## Post Configuration

### Datasource Configuration
Now we need to create the Prometheus Datasource in order to connect Grafana to Prometheus
* Click the `Grafana` Menu at the top left corner (looks like a fireball)
* Click `Data Sources`
* Click the green button `Add Data Source`.
* Input the following parameters **exactly as shown**
* Name - `Prometheus`, Default - `checked`
* Type - `Prometheus`
* HTTP settings
* URL - `http://prometheus:9090`
* Access - `proxy`
* Click `Save & Test`

<img src="images/add-data-source.png" alt="Add Data Source">

### Ping Configuration

If you would like to add or change the Ping targets should be monitored you'll want to edit the `targets` section in [prometheus/prometheus.yml](prometheus/prometheus.yml)
Expand Down
2 changes: 0 additions & 2 deletions config.monitoring
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
GF_SECURITY_ADMIN_PASSWORD=9uT46ZKE
GF_DASHBOARDS_JSON_ENABLED=true
GF_DASHBOARDS_JSON_PATH=/var/lib/grafana/dashboards
3 changes: 2 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,14 +72,15 @@ services:
mode: global

grafana:
image: grafana/grafana:4.6.3
image: grafana/grafana:5.4.2
depends_on:
- prometheus
ports:
- 3000:3000
volumes:
- grafana_data:/var/lib/grafana
- ./grafana/dashboards:/var/lib/grafana/dashboards
- ./grafana/provisioning:/etc/grafana/provisioning
env_file:
- config.monitoring

Expand Down
11 changes: 11 additions & 0 deletions grafana/provisioning/dashboards/all.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
apiVersion: 1

providers:
- name: 'default'
orgId: 1
folder: ''
type: file
disableDeletion: false
updateIntervalSeconds: 10 #how often Grafana will scan for changed dashboards
options:
path: /var/lib/grafana/dashboards
20 changes: 20 additions & 0 deletions grafana/provisioning/datasources/all.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# config file version
apiVersion: 1

# list of datasources that should be deleted from the database
deleteDatasources:
- name: Prometheus
orgId: 1

# list of datasources to insert/update depending
# whats available in the database
datasources:
# <string, required> name of the datasource. Required
- name: 'Prometheus'
type: 'prometheus'
access: 'proxy'
org_id: 1
url: 'http://prometheus:9090'
is_default: true
version: 1
editable: true

0 comments on commit 16bf3fb

Please sign in to comment.