Skip to content

Commit 4afa9f0

Browse files
author
hugovalente-pm
committed
review installation section
1 parent 3ba551c commit 4afa9f0

File tree

1 file changed

+18
-32
lines changed

1 file changed

+18
-32
lines changed

README.md

Lines changed: 18 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,11 @@ Once you have added your API token to Netdata data source plugin you’re ready
4949
To start using the Netdata data source plugin on your Grafana environment, local or Cloud, you need to install the plugin manually - it currently isn't signed. Here are some tips to get through this depending on your setup:
5050
* Docker
5151
* Linux (local)
52-
* Windows (local)
52+
* Windows (local - powershell)
5353
* Building the plugin locally
5454

55+
The installations below will use different tools like: curl, docker, jq, wget, unzip and xcopy.
56+
5557
### Docker
5658

5759
#### Pre-buit script - setup-demo-environment
@@ -83,40 +85,31 @@ This script will:
8385
2. Ensure you have the desired version of the plugin you want to install, get it from github releases
8486

8587
```
86-
curl -s https://api.github.com/repos/netdata/netdata-grafana-datasource-plugin/releases/latest \
87-
jq -r '.assets[] | select(.name|match("zip$")) | .browser_download_url'
88+
wget `curl -s https://api.github.com/repos/netdata/netdata-grafana-datasource-plugin/releases/latest | jq -r '.assets[] | select(.name|match("zip$")) | .browser_download_url'`
8889
```
8990

90-
3. Grafana plugins, by default, should be under /var/lib/grafana/plugins. Create a folder for netdata inside the container. Enter in an interactive session
91+
3. Copy the contents of the Netdata data source plugin to Grafana plugins directory, by default /var/lib/grafana/plugins
9192

9293
```
93-
docker exec -ti grafana bash
94-
mkdir /var/lib/grafana/plugins/netdata
94+
unzip netdata-datasource-<version_number>.zip
95+
docker cp netdata-datasource grafana:/var/lib/grafana/plugins/
9596
```
9697

97-
4. Copy the contents of the Netdata data source plugin to the new plugin folder created on step 2
98-
98+
4. Restart grafana container
99+
99100
```
100-
unzip netdata-datasource-<version_number>.zip
101-
docker cp netdata-datasource grafana:/var/lib/grafana/plugins/netdata/
101+
docker restart grafana
102102
```
103103

104104
### Linux (local)
105105

106106
1. Ensure you have the desired version of the plugin you want to install, get it from github releases
107107

108108
```
109-
curl -s https://api.github.com/repos/netdata/netdata-grafana-datasource-plugin/releases/latest \
110-
jq -r '.assets[] | select(.name|match("zip$")) | .browser_download_url'
109+
wget `curl -s https://api.github.com/repos/netdata/netdata-grafana-datasource-plugin/releases/latest | jq -r '.assets[] | select(.name|match("zip$")) | .browser_download_url'`
111110
```
112111

113-
2. Grafana plugins, by default, should be under /var/lib/grafana/plugins. Create a folder for netdata
114-
115-
```
116-
mkdir /var/lib/grafana/plugins/netdata
117-
```
118-
119-
3. Copy the contents of the Netdata data source plugin to the new plugin folder created on step 2
112+
2. Copy the contents of the Netdata data source plugin to Grafana plugins directory, by default /var/lib/grafana/plugins
120113

121114
```
122115
unzip netdata-datasource-<version_number>.zip
@@ -147,14 +140,11 @@ This script will:
147140
systemctl restart grafana-server
148141
```
149142

150-
### Windows (local)
143+
### Windows (local - powershell)
151144

152-
1. Ensure you have the desired version of the plugin you want to install, get it from github releases
153-
154-
```
155-
curl -s https://api.github.com/repos/netdata/netdata-grafana-datasource-plugin/releases/latest \
156-
jq -r '.assets[] | select(.name|match("zip$")) | .browser_download_url'
157-
```
145+
1. Ensure you have the desired version of the plugin you want to install, get it from github releases by:
146+
* Going to https://github.com/netdata/netdata-grafana-datasource-plugin/releases/latest
147+
* Downloading the zip file with the latest release, e.g. netdata-datasource-1.0.12.zip
158148

159149
2. Grafana plugins, by default, should be under C:\Program Files\GrafanaLabs\grafana\data\plugins. Create a folder for netdata
160150

@@ -165,12 +155,8 @@ This script will:
165155
3. Copy the contents of the Netdata data source plugin to the new plugin folder created on step 2
166156

167157
```
168-
wzunzip -d netdata-datasource-<version_number>.zip
169-
```
170-
or
171-
```
172-
gzip -d < netdata-datasource-<version_number>.zip
173-
cp .\netdata-datasource\* "C:\Program Files\GrafanaLabs\grafana\data\plugins\netdata"
158+
Expand-Archive \.netdata-datasource-<version_number>.zip \.
159+
xcopy .\netdata-datasource\ "C:\Program Files\GrafanaLabs\grafana\data\plugins\netdata-datasource\" /E
174160
```
175161

176162
4. Ensure that Netdata plugin which currently isn’t signed can be registered

0 commit comments

Comments
 (0)