Skip to content
This repository has been archived by the owner on Sep 7, 2018. It is now read-only.

Commit

Permalink
Notes on how to create an image with pre-installed plugins.
Browse files Browse the repository at this point in the history
  • Loading branch information
xlson authored Mar 7, 2018
1 parent d2ebbcb commit 04caf1b
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,28 @@ docker run \
grafana/grafana
```

## Building a custom Grafana image with pre-installed plugins

Dockerfile:
```Dockerfile
FROM grafana/grafana:5.0.0
ENV GF_PATHS_PLUGINS=/opt/grafana-plugins
RUN mkdir -p $GF_PATHS_PLUGINS
RUN grafana-cli --pluginsDir $GF_PATHS_PLUGINS plugins install grafana-clock-panel
```

Add lines with `RUN grafana-cli ...` for each plugin you wish to install in your custom image. Don't forget to specify what version of Grafana you wish to build from (replace 5.0.0 in the example).

Example of how to build and run:
```bash
docker build -t grafana:5.0.0-custom .
docker run \
-d \
-p 3000:3000 \
--name=grafana \
grafana:5.0.0-custom
```

## Running specific version of Grafana

```
Expand Down

0 comments on commit 04caf1b

Please sign in to comment.