Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add telegraf-ds (imported and updated from old tick-stack charts) #16

Merged
merged 11 commits into from
Feb 28, 2020
Merged
21 changes: 21 additions & 0 deletions charts/telegraf-ds/.helmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Patterns to ignore when building packages.
# This supports shell glob matching, relative path matching, and
# negation (prefixed with !). Only one pattern per line.
.DS_Store
# Common VCS dirs
.git/
.gitignore
.bzr/
.bzrignore
.hg/
.hgignore
.svn/
# Common backup files
*.swp
*.bak
*.tmp
*~
# Various IDEs
.project
.idea/
*.tmproj
22 changes: 22 additions & 0 deletions charts/telegraf-ds/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
apiVersion: v1
name: telegraf-ds
version: 1.0.0
appVersion: 1.13
deprecated: false
description: Telegraf is an agent written in Go for collecting, processing, aggregating, and writing metrics.
keywords:
- telegraf
- collector
- timeseries
- influxdata
home: https://www.influxdata.com/time-series-platform/telegraf/
maintainers:
- name: rawkode
email: [email protected]
- name: gitirabassi
email: [email protected]
- name: naseemkullah
email: [email protected]
- name: nsteinmetz
email: [email protected]
engine: gotpl
8 changes: 8 additions & 0 deletions charts/telegraf-ds/OWNER
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
approvers:
- rawkode
- gitirabassi
- naseemkullah
reviewers:
- rawkode
- gitirabassi
- naseemkullah
76 changes: 76 additions & 0 deletions charts/telegraf-ds/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
# Telegraf-DS (DaemonSet)

[Telegraf](https://github.com/influxdata/telegraf) is a plugin-driven server agent written by the folks over at [InfluxData](https://influxdata.com) for collecting & reporting metrics. This chart runs a DaemonSet of Telegraf instances to collect host level metrics for your cluster. If you need to poll individual instances of infrastructure or APIs there is a `telegraf` chart that is more suited to that usecase.

Telegraf input cannot be customised as it aims to provide an opinionated configuration to monitor kubernetes nodes and global kubernetes monitoring.

## TL;DR

```console
helm repo add influxdata https://helm.influxdata.com/
helm install influxdata/telegraf-ds
```

## Introduction

This chart bootstraps a `telegraf-ds` daemonset on a [Kubernetes](http://kubernetes.io) cluster using the [Helm](https://helm.sh) package manager.

## Prerequisites

- Kubernetes 1.11+ with Beta APIs enabled

## Installing the Chart

To install the chart with the release name `my-release`:

```console
helm install --name my-release influxdata/telegraf-ds
```

The command deploys a Telegraf daemonset on the Kubernetes cluster in the default configuration. The [configuration](#configuration) section as well as the [values.yaml](/values.yaml) file lists the parameters that can be configured during installation.

> **Tip**: List all releases using `helm list`

## Uninstalling the Chart

To uninstall/delete the `my-release` deployment:

```console
helm delete my-release
```

The command removes all the Kubernetes components associated with the chart and deletes the release.

## Configuration

The default configuration parameters are listed in `values.yaml`. To change the defaults, specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example,

```console
helm install --name my-release \
--set config.outputs.influxdb.url=http://foo.bar:8086 \
influxdata/telegraf-ds
```

The above command allows the chart to deploy by setting the InfluxDB URL for telegraf to write to.

Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the chart. For example,

```console
helm install --name my-release -f values.yaml influxdata/telegraf-ds
```

## Telegraf Configuration

This chart deploys the following by default:

- `telegraf` (`telegraf-ds`) running in a daemonset with the following plugins enabled
* [`cpu`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/cpu)
* [`disk`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/disk)
* [`diskio`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/diskio)
* [`docker`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/docker)
* [`kernel`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/kernel)
* [`kubernetes`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/kubernetes)
* [`mem`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/mem)
* [`processes`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/processes)
* [`swap`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/swap)
* [`system`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/system)
11 changes: 11 additions & 0 deletions charts/telegraf-ds/templates/NOTES.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
To open a shell session in the container running Telegraf run the following:

- kubectl exec -i -t --namespace {{ .Release.Namespace }} $(kubectl get pods --namespace {{ .Release.Namespace }} -l app.kubernetes.io/name={{ include "telegraf.name" . }} -o jsonpath='{.items[0].metadata.name}') /bin/sh

To tail the logs for a Telegraf pod in the Daemonset run the following:

- kubectl logs -f --namespace {{ .Release.Namespace }} $(kubectl get pods --namespace {{ .Release.Namespace }} -l app.kubernetes.io/name={{ include "telegraf.name" . }} -o jsonpath='{ .items[0].metadata.name }')

To list the running Telegraf instances run the following:

- kubectl get pods --namespace {{ .Release.Namespace }} -l app.kubernetes.io/name={{ include "telegraf.name" . }} -w
Loading