Skip to content

Commit

Permalink
Merge pull request #73 from grafana/update_main_page
Browse files Browse the repository at this point in the history
Update installation instructions
  • Loading branch information
MichelHollands authored Apr 24, 2024
2 parents 329d582 + c666bf6 commit 2d711f7
Show file tree
Hide file tree
Showing 2 changed files with 75 additions and 24 deletions.
20 changes: 1 addition & 19 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,9 @@
# meta-monitoring-chart

This is a meta-monitoring chart for GEL, GEM and GET. It should be installed in a
separate namespace next to GEM, GEL or GET installations.
This is a meta-monitoring chart for Loki.

Note that this is pre-production software at the moment.

## Preparation

Create a values.yaml file based on the [default one](../charts/meta-monitoring/values.yaml).

1. Add or remove the namespaces to monitor in the `namespacesToMonitor` setting

1. Set the cluster name in the `clusterName` setting. This will be added as a label to all logs, metrics and traces.

1. Create a `meta` namespace.

## Local and cloud modes

The chart has 2 modes: local and cloud. In the local mode logs, metrics and/or traces are sent
Expand All @@ -34,12 +23,6 @@ Both modes can be enabled at the same time.

## Installation

```
helm install -n meta --skip-crds -f values.yaml meta ./charts/meta-monitoring
```

If the platform supports CRDs the `--skip-crds` option can be removed. However the CRDs are not used by this chart.

For more instructions including how to update the chart go to the [installation](docs/installation.md) page.

## Supported features
Expand All @@ -59,7 +42,6 @@ Most of these features are enabled by default. See the values.yaml file for how

## Caveats

- The [loki.source.kubernetes](https://grafana.com/docs/agent/latest/flow/reference/components/loki.source.kubernetes/) component of the Grafana Agent is used to scrape Kubernetes log files. This component is marked experimental at the moment.
- This has not been tested on Openshift yet.
- The underlying Loki, Mimir and Tempo are at the default size installed by the Helm chart. This might need changing when monitoring bigger Loki, Mimir or Tempo installations.
- MinIO is used as storage at the moment with a limited retention. At the moment this chart cannot be used for monitoring over longer periods.
Expand Down
79 changes: 74 additions & 5 deletions docs/installation.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,19 @@
# Install this chart

## Preparation for Cloud mode (preferred)

1. Use an existing Grafana Cloud account or setup a new one. Then create an access token:

1. In Grafana go to Administration -> Users and Access -> Cloud access policies.

1. Click `Create access policy`.

1. Fill in the `Display name` field and check the `Write` check box for metrics, logs and traces. Then click `Create`.

1. On the newly created access policy click `Add token`.

1. Fill in the `Token name` field and click `Create`. Make a copy of the token as it will be used later on.

1. Create the meta namespace

```
Expand All @@ -11,21 +25,76 @@
```
kubectl create secret generic logs -n meta \
--from-literal=username=<logs username> \
--from-literal=password=<logs password>
--from-literal=password=<token>
--from-literal=endpoint='https://logs-prod-us-central1.grafana.net/loki/api/v1/push'
kubectl create secret generic metrics -n meta \
--from-literal=username=<metrics username> \
--from-literal=password=<metrics password>
--from-literal=password=<token>
--from-literal=endpoint='https://prometheus-us-central1.grafana.net/api/prom/push'
kubectl create secret generic traces -n meta \
--from-literal=username=<traces username> \
--from-literal=password=<traces password>
--from-literal=password=<token>
--from-literal=endpoint='https://tempo-us-central1.grafana.net/tempo'
```

1. Create a values.yaml file based on the [default one](../charts/meta-monitoring/values.yaml). Fill in the names of the secrets created above as needed.
The logs, metrics and traces usernames are the `User / Username / Instance IDs` of the Loki, Prometheus/Mimir and Tempo instances in Grafana Cloud. From `Home` in Grafana click on `Stacks`. Then go to the `Details` pages of Loki, Prometheus/Mimir and Tempo.

1. Create a values.yaml file based on the [default one](../charts/meta-monitoring/values.yaml). Fill in the names of the secrets created above as needed. An example minimal values.yaml looks like this:

```
namespacesToMonitor:
- loki
cloud:
logs:
enabled: true
secret: "logs"
metrics:
enabled: true
secret: "metrics"
traces:
enabled: true
secret: "traces"
```

## Preparation for Local mode

1. Create the meta namespace

```
kubectl create namespace meta
```

1. Create a values.yaml file based on the [default one](../charts/meta-monitoring/values.yaml). An example minimal values.yaml looks like this:

```
namespacesToMonitor:
- loki
cloud:
logs:
enabled: false
metrics:
enabled: false
traces:
enabled: false
local:
grafana:
enabled:true
logs:
enabled: true
metrics:
enabled: true
traces:
enabled: true
minio:
enabled: true
```

## Installing the chart

1. Add the repo

Expand Down Expand Up @@ -56,4 +125,4 @@

```
helm delete -n meta meta
```
```

0 comments on commit 2d711f7

Please sign in to comment.