Version information
This version is compatible with:
- Puppet Enterprise 2019.8.x, 2019.7.x, 2019.5.x, 2019.4.x, 2019.3.x, 2019.2.x, 2019.1.x
- Puppet >= 6.1.0 < 7.0.0
- , ,
Start using this module
Add this module to your Puppetfile:
mod 'kogitoapp-chronograf', '1.0.3'
Learn more about managing modules with a PuppetfileDocumentation
Puppet module to manage Chronograf
Table of Contents
- Description
- Setup - The basics of getting started with chronograf
- Usage - Configuration options and additional functionality
- Limitations - OS compatibility, etc.
- Development - Guide for contributing to the module
Description
Installs, configures and manages Chronograf, the monitoring and visualization UI of the Tick stack.
Setup
What chronograf affects
Default configuration
-
manages GPG key, repository (default:
manage_repo = true
)- default:
repo_location = https://repos.influxdata.com/
andrepo_type = 'stable'
- default:
-
manages package
-
manages directories and configuration files (referring to templates)
-
Debian:
/lib/systemd/system/chronograf.service
-
CentOS:
/etc/systemd/system/chronograf.service
-
/etc/default/chronograf
-
-
starts service "chronograf" immediately (default:
manage_service = true
) -
set up connection to influx and kapacitor upon request, also based on templates
/usr/share/chronograf/resources/
Setup Requirements
For an extensive list of requirements, see metadata.json
.
Beginning with chronograf
The module comes along with several configuration files (see templates). Change configuration settings in according hiera level or via hash.
-
service-defaults.erb
- following keys are supported to be added in single line mode
- host = '0.0.0.0'
- port = 8888
- tls_certificate
- token_secret
- log_level ['error','warn','info','debug']
- public_url
- generic_client_id
- generic_client_secret
- generic_auth_url
- generic_token_url
- use_id_token ['true','false']
- jwks_url
- generic_api_url
- generic_api_key
- generic_scopes
- generic_domains
- generic_name
- google_client_id
- google_client_secret
- google_domains
- following keys are supported to be added in single line mode
-
systemd.service.erb
-
With two defines setup the connection to influx and kapacitor.
Please refer to Chronograf documentation for the defaults used.
Usage
In combination with other influxdata module
- when one of the other influxdata modules already handles GPG keys and repository
class { 'chronograf':
manage_repo => false,
}
- when chronograf shall handle GPG keys and repository
class { 'chronograf':
manage_repo => true,
}
Example
class { 'chronograf':
manage_repo => true,
host => '127.0.0.90',
tls_certificate => 'cert-bar',
log_level => 'info',
use_id_token => 'false',
}
chronograf::connection::influx { 'MyInfluxDB':
ensure => 'present',
id => '10000',
username => 'telegraf',
password => 'metricsmetricsmetrics',
url => 'http://localhost:8086',
type => 'influx',
insecure_skip_verify => false,
default => true,
telegraf => 'telegraf',
organization => 'example_org',
}
chronograf::connection::kapacitor { 'MyKapacitor':
ensure => 'present',
id => '10010',
src_id => '10010',
url => 'http://localhost:9092',
active => true,
organization => 'example_org',
}
Reference
Please see document REFERENCE.md
.
Limitations
For an extensive list of supported operating systems, see metadata.json
.
Release Notes/Contributors/Etc.
- module: kogitoapp-chronograf
- version: 1.0.0
- author: Kogito UG hello@kogito.network
- summary: Module for configuring Chronograf
- license: Apache-2.0
- source: https://github.com/kogitoapp/puppet-chronograf
Reference
Table of Contents
Classes
chronograf
: Manages a Chronografchronograf::config
: Manages directories and files; service defaultschronograf::install
: Manages packagechronograf::params
: Parameter definitonchronograf::repo
: Manages gpg key information and repository, if necessarychronograf::service
: Manages the service
Defined types
chronograf::connection::influx
: Manages the connections to influxchronograf::connection::kapacitor
: Manages the connections to kapacitor
Classes
chronograf
Manages a Chronograf
Examples
include chronograf
Parameters
The following parameters are available in the chronograf
class.
manage_repo
Data type: Boolean
Default value: $chronograf::params::manage_repo
package_name
Data type: String
Default value: $chronograf::params::package_name
ensure
Data type: String
Default value: $chronograf::params::ensure
repo_location
Data type: Stdlib::HTTPSUrl
Default value: $chronograf::params::repo_location
repo_type
Data type: String
Default value: $chronograf::params::repo_type
group
Data type: String
Default value: $chronograf::params::group
user
Data type: String
Default value: $chronograf::params::user
service_defaults
Data type: Stdlib::Absolutepath
Default value: $chronograf::params::service_defaults
service_definition
Data type: Stdlib::Absolutepath
Default value: $chronograf::params::service_definition
service_definition_template
Data type: String
Default value: $chronograf::params::service_definition_template
service_name
Data type: String
Default value: $chronograf::params::service_name
service_provider
Data type: String
Default value: $chronograf::params::service_provider
service_ensure
Data type: Stdlib::Ensure::Service
Default value: $chronograf::params::service_ensure
service_enable
Data type: Boolean
Default value: $chronograf::params::service_enable
service_has_status
Data type: Boolean
Default value: $chronograf::params::service_has_status
service_has_restart
Data type: Boolean
Default value: $chronograf::params::service_has_restart
manage_service
Data type: Boolean
Default value: $chronograf::params::manage_service
bolt_path
Data type: Stdlib::Absolutepath
Default value: $chronograf::params::bolt_path
canned_path
Data type: Stdlib::Absolutepath
Default value: $chronograf::params::canned_path
protoboards_path
Data type: Stdlib::Absolutepath
Default value: $chronograf::params::protoboards_path
resources_path
Data type: Stdlib::Absolutepath
Default value: $chronograf::params::resources_path
basepath
Data type: Optional[Stdlib::Absolutepath]
Default value: $chronograf::params::basepath
status_feed_url
Data type: Optional[Stdlib::HTTPSUrl]
Default value: $chronograf::params::status_feed_url
connection_influx
Data type: Hash
Default value: $chronograf::params::connection_influx
influx_connection_template
Data type: String
Default value: $chronograf::params::influx_connection_template
connection_kapacitor
Data type: Hash
Default value: $chronograf::params::connection_kapacitor
kapacitor_connection_template
Data type: String
Default value: $chronograf::params::kapacitor_connection_template
host
Data type: Stdlib::Host
Default value: $chronograf::params::host
port
Data type: Stdlib::Port
Default value: $chronograf::params::port
tls_certificate
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::params::tls_certificate
token_secret
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::params::token_secret
log_level
Data type: Variant[Undef, Enum['UNSET'], Enum['error','warn','info','debug']]
Default value: $chronograf::params::log_level
public_url
Data type: Variant[Undef, Enum['UNSET'], Stdlib::HTTPUrl]
Default value: $chronograf::params::public_url
generic_client_id
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::params::generic_client_id
generic_client_secret
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::params::generic_client_secret
generic_auth_url
Data type: Variant[Undef, Enum['UNSET'], Stdlib::HTTPSUrl]
Default value: $chronograf::params::generic_auth_url
generic_token_url
Data type: Variant[Undef, Enum['UNSET'], Stdlib::HTTPSUrl]
Default value: $chronograf::params::generic_token_url
use_id_token
Data type: Variant[Undef, Enum['UNSET'], Enum['true','false']]
Default value: $chronograf::params::use_id_token
jwks_url
Data type: Variant[Undef, Enum['UNSET'], Stdlib::HTTPSUrl]
Default value: $chronograf::params::jwks_url
generic_api_url
Data type: Variant[Undef, Enum['UNSET'], Stdlib::HTTPSUrl]
Default value: $chronograf::params::generic_api_url
generic_api_key
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::params::generic_api_key
generic_scopes
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::params::generic_scopes
generic_domains
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::params::generic_domains
generic_name
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::params::generic_name
google_client_id
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::params::google_client_id
google_client_secret
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::params::google_client_secret
google_domains
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::params::google_domains
chronograf::config
Manages directories and files; service defaults
Examples
include chronograf::config
Parameters
The following parameters are available in the chronograf::config
class.
service_defaults
Data type: Stdlib::Absolutepath
Default value: $chronograf::service_defaults
service_definition
Data type: Stdlib::Absolutepath
Default value: $chronograf::service_definition
service_definition_template
Data type: String
Default value: $chronograf::service_definition_template
resources_path
Data type: String
Default value: $chronograf::resources_path
user
Data type: String
Default value: $chronograf::user
group
Data type: String
Default value: $chronograf::group
bolt_path
Data type: Stdlib::Absolutepath
Default value: $chronograf::bolt_path
canned_path
Data type: Stdlib::Absolutepath
Default value: $chronograf::canned_path
protoboards_path
Data type: Stdlib::Absolutepath
Default value: $chronograf::protoboards_path
basepath
Data type: Optional[Stdlib::Absolutepath]
Default value: $chronograf::basepath
status_feed_url
Data type: Optional[Stdlib::HTTPSUrl]
Default value: $chronograf::status_feed_url
host
Data type: Stdlib::Host
Default value: $chronograf::host
port
Data type: Stdlib::Port
Default value: $chronograf::port
tls_certificate
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::tls_certificate
token_secret
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::token_secret
log_level
Data type: Variant[Undef, Enum['UNSET'], Enum['error','warn','info','debug']]
Default value: $chronograf::log_level
public_url
Data type: Variant[Undef, Enum['UNSET'], Stdlib::HTTPUrl]
Default value: $chronograf::public_url
generic_client_id
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::generic_client_id
generic_client_secret
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::generic_client_secret
generic_auth_url
Data type: Variant[Undef, Enum['UNSET'], Stdlib::HTTPSUrl]
Default value: $chronograf::generic_auth_url
generic_token_url
Data type: Variant[Undef, Enum['UNSET'], Stdlib::HTTPSUrl]
Default value: $chronograf::generic_token_url
use_id_token
Data type: Variant[Undef, Enum['UNSET'], Enum['true','false']]
Default value: $chronograf::use_id_token
jwks_url
Data type: Variant[Undef, Enum['UNSET'], Stdlib::HTTPSUrl]
Default value: $chronograf::jwks_url
generic_api_url
Data type: Variant[Undef, Enum['UNSET'], Stdlib::HTTPSUrl]
Default value: $chronograf::generic_api_url
generic_api_key
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::generic_api_key
generic_scopes
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::generic_scopes
generic_domains
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::generic_domains
generic_name
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::generic_name
google_client_id
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::google_client_id
google_client_secret
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::google_client_secret
google_domains
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: $chronograf::google_domains
chronograf::install
Manages package
Examples
include chronograf::install
Parameters
The following parameters are available in the chronograf::install
class.
ensure
Data type: String
Default value: $chronograf::ensure
package_name
Data type: String
Default value: $chronograf::package_name
chronograf::params
Parameter definiton
Examples
include chronograf::params
Parameters
The following parameters are available in the chronograf::params
class.
manage_repo
Data type: Boolean
Default value: true
package_name
Data type: String
Default value: 'chronograf'
ensure
Data type: String
Default value: 'present'
repo_location
Data type: Stdlib::HTTPSUrl
Default value: 'https://repos.influxdata.com/'
repo_type
Data type: String
Default value: 'stable'
group
Data type: String
Default value: 'chronograf'
user
Data type: String
Default value: 'chronograf'
service_defaults
Data type: Stdlib::Absolutepath
Default value: '/etc/default/chronograf'
service_definition
Data type: Stdlib::Absolutepath
Default value: '/lib/systemd/system/chronograf.service'
service_definition_template
Data type: String
Default value: 'chronograf/systemd.service.erb'
service_name
Data type: String
Default value: 'chronograf'
service_provider
Data type: String
Default value: 'systemd'
service_ensure
Data type: Stdlib::Ensure::Service
Default value: 'running'
service_enable
Data type: Boolean
Default value: true
service_has_status
Data type: Boolean
Default value: true
service_has_restart
Data type: Boolean
Default value: true
manage_service
Data type: Boolean
Default value: true
bolt_path
Data type: Stdlib::Absolutepath
Default value: '/var/lib/chronograf/chronograf-v1.db'
canned_path
Data type: Stdlib::Absolutepath
Default value: '/usr/share/chronograf/canned'
protoboards_path
Data type: Stdlib::Absolutepath
Default value: '/usr/share/chronograf/protoboards'
resources_path
Data type: Stdlib::Absolutepath
Default value: '/usr/share/chronograf/resources'
basepath
Data type: Optional[Stdlib::Absolutepath]
Default value: '/usr/share/chronograf/base'
status_feed_url
Data type: Stdlib::HTTPSUrl
Default value: 'https://www.influxdata.com/feed/json'
connection_influx
Data type: Hash
Default value: {}
influx_connection_template
Data type: String
Default value: 'chronograf/influx_connection.erb'
connection_kapacitor
Data type: Hash
Default value: {}
kapacitor_connection_template
Data type: String
Default value: 'chronograf/kapacitor_connection.erb'
host
Data type: Stdlib::Host
Default value: '0.0.0.0'
port
Data type: Stdlib::Port
Default value: 8888
tls_certificate
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: 'UNSET'
token_secret
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: 'UNSET'
log_level
Data type: Variant[Undef, Enum['UNSET'], Enum['error','warn','info','debug']]
Default value: 'UNSET'
public_url
Data type: Variant[Undef, Enum['UNSET'], Stdlib::HTTPUrl]
Default value: 'UNSET'
generic_client_id
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: 'UNSET'
generic_client_secret
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: 'UNSET'
generic_auth_url
Data type: Variant[Undef, Enum['UNSET'], Stdlib::HTTPSUrl]
Default value: 'UNSET'
generic_token_url
Data type: Variant[Undef, Enum['UNSET'], Stdlib::HTTPSUrl]
Default value: 'UNSET'
use_id_token
Data type: Variant[Undef, Enum['UNSET'], Enum['true','false']]
Default value: 'UNSET'
jwks_url
Data type: Variant[Undef, Enum['UNSET'], Stdlib::HTTPSUrl]
Default value: 'UNSET'
generic_api_url
Data type: Variant[Undef, Enum['UNSET'], Stdlib::HTTPSUrl]
Default value: 'UNSET'
generic_api_key
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: 'UNSET'
generic_scopes
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: 'UNSET'
generic_domains
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: 'UNSET'
generic_name
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: 'UNSET'
google_client_id
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: 'UNSET'
google_client_secret
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: 'UNSET'
google_domains
Data type: Variant[Undef, Enum['UNSET'], String]
Default value: 'UNSET'
chronograf::repo
Manages gpg key information and repository, if necessary
Examples
include chronograf::repo
Parameters
The following parameters are available in the chronograf::repo
class.
manage_repo
Data type: Boolean
Default value: $chronograf::manage_repo
repo_location
Data type: Stdlib::HTTPSUrl
Default value: $chronograf::repo_location
repo_type
Data type: String
Default value: $chronograf::repo_type
chronograf::service
Manages the service
Examples
include chronograf::service
Parameters
The following parameters are available in the chronograf::service
class.
service_name
Data type: String
Default value: $chronograf::service_name
service_ensure
Data type: Stdlib::Ensure::Service
Default value: $chronograf::service_ensure
service_enable
Data type: Boolean
Default value: $chronograf::service_enable
service_has_status
Data type: Boolean
Default value: $chronograf::service_has_status
service_has_restart
Data type: Boolean
Default value: $chronograf::service_has_restart
service_provider
Data type: String
Default value: $chronograf::service_provider
manage_service
Data type: Boolean
Default value: $chronograf::manage_service
service_definition
Data type: Stdlib::Absolutepath
Default value: $chronograf::service_definition
Defined types
chronograf::connection::influx
Manages the connections to influx
Examples
chronograf::connection::influx { 'connection': }
Parameters
The following parameters are available in the chronograf::connection::influx
defined type.
connection
Data type: String
Default value: $title
ensure
Data type: Enum['present', 'absent']
Default value: 'present'
id
Data type: String
Default value: '10000'
username
Data type: String
Default value: 'test'
password
Data type: String
Default value: 'test'
url
Data type: Stdlib::HTTPUrl
Default value: 'http://localhost:8086'
type
Data type: String
Default value: 'influx'
insecure_skip_verify
Data type: Boolean
Default value: false
default
Data type: Boolean
Default value: true
telegraf
Data type: String
Default value: 'telegraf'
organization
Data type: String
Default value: 'example_org'
connection_template
Data type: String
Default value: $chronograf::influx_connection_template
resources_path
Data type: Stdlib::Absolutepath
Default value: $chronograf::resources_path
chronograf::connection::kapacitor
Manages the connections to kapacitor
Examples
chronograf::connection::kapacitor { 'connection': }
Parameters
The following parameters are available in the chronograf::connection::kapacitor
defined type.
connection
Data type: String
Default value: $title
ensure
Data type: Enum['present', 'absent']
Default value: 'present'
id
Data type: String
Default value: '10000'
src_id
Data type: String
Default value: '10000'
url
Data type: Stdlib::HTTPUrl
Default value: 'http://localhost:9092'
active
Data type: Boolean
Default value: true
organization
Data type: String
Default value: 'example_org'
connection_template
Data type: String
Default value: $chronograf::kapacitor_connection_template
resources_path
Data type: Stdlib::Absolutepath
Default value: $chronograf::resources_path
Change log
This list contains all the changes which went into the project, including issues and further references.
Items starting with DEPRECATION
are important deprecation notices.
1.0.3 (2021-09-23)
- [Changed] to support 8.x version of puppetlabs/apt
- [Added] support for CentOS 8
- [Added] support for Debian 11
- [Added] support for Ubuntu 20.04
- [Improved] CI pipelines that run on PR
1.0.2 (2021-07-28)
- [Changed] version to 1.0.2
- [Fixed] missing build dependencies
1.0.1 (2021-07-28)
- [Changed] version to 1.0.1
- [Removed] systemctl daemon reload
1.0.0 (2021-07-11)
- [Changed] version to 1.0.0
- [Changed] to PDK 2.1 template
- [Changed] README and REFERENCE
- [Changed] examples
- [Fixed] Rubocop errors
- [Improved] module
- [Removed] duplicate host/port configuration
- [Removed]
default_
from variables - [Fixed] tests
- [Changed] service w/o host/port
- [Changed] rspec augeas resoures
- [Fixed] RuboCop offenses
- [Changed] rspecs
- [Changed] update pdk 18.1.1
- [Fixed] RuboCop offenses
- [Changed] rspec for defines
- [Changed] documentation
- [Changed] OS Debian 10
- [Fixed] yumrepo relationship
- [Changed] Puppet version and yumrepo w/o name
- [Changed] double row
- [Changed] yumrepo
- [Changed] service spec - let files be there
- [Changed] clean: default service template
- [Changed] typo
- [Changed] additional defaults
- [Changed] augeas with each+getvar
- [Changed] defaults to use UNSET
- [Fixed] params for defaults no undef
- [Changed] using augeas for /etc/default
- [Changed] required by review 3
- [Changed] requested by reviewer 2
- [Changed] requested by reviewer
- [Changed] config spec - defaults service
- [Changed] use systemd of camptocamp
- [Added] default service parameter
- [Fixed] RuboCop offenses
- [Fixed] RuboCop offenses
- [Changed] specs
- [Removed] invalid comments from JSON
- [Fixed] yumrepo and typo
- [Added] some specs
- [Added] some specs
- [Changed] URL to point to official documentation
- [Fixed] typos
- [Added] confit, templates, spec
Dependencies
- puppetlabs/apt (>= 2.0.0 < 9.0.0)
- puppetlabs/augeas_core (>= 1.0.0 < 2.0.0)
- puppetlabs/concat (>= 5.0.0 < 7.0.0)
- puppetlabs/stdlib (>= 4.25.0 < 7.0.0)
- puppetlabs/translate (>= 1.0.0 < 3.0.0)
- puppetlabs/yumrepo_core (>= 1.0.0 < 2.0.0)
- camptocamp/systemd (>= 2.0.0 < 4.0.0)
The MIT License (MIT) Copyright © 2021 Kogito UG <hello+github@kogito.network> Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.