telegraf/plugins/inputs/cgroup/cgroup.go

27 lines
551 B
Go
Raw Normal View History

//go:generate ../../../tools/readme_config_includer/generator
2016-06-08 16:13:22 +08:00
package cgroup
import (
_ "embed"
2016-06-08 16:13:22 +08:00
"github.com/influxdata/telegraf"
"github.com/influxdata/telegraf/plugins/inputs"
)
// DO NOT REMOVE THE NEXT TWO LINES! This is required to embedd the sampleConfig data.
//go:embed sample.conf
var sampleConfig string
2016-06-08 16:13:22 +08:00
type CGroup struct {
2016-06-23 16:11:44 +08:00
Paths []string `toml:"paths"`
Files []string `toml:"files"`
2016-06-08 16:13:22 +08:00
}
func (*CGroup) SampleConfig() string {
return sampleConfig
}
2016-06-08 16:13:22 +08:00
func init() {
inputs.Add("cgroup", func() telegraf.Input { return &CGroup{} })
}