36 changes: 22 additions & 14 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,32 @@
# Changelog

## [v4.5.0](https://github.com/sensu/sensu-puppet/tree/v4.5.0) (2020-02-07)
## [v4.5.1](https://github.com/sensu/sensu-puppet/tree/v4.5.1) (2020-02-12)

[Full Changelog](https://github.com/sensu/sensu-puppet/compare/v4.5.0...v4.5.1)

### Added

- Add more examples [\#1214](https://github.com/sensu/sensu-puppet/pull/1214) ([treydock](https://github.com/treydock))
- Better organization of class variables [\#1213](https://github.com/sensu/sensu-puppet/pull/1213) ([treydock](https://github.com/treydock))
- Better documentation of private types [\#1212](https://github.com/sensu/sensu-puppet/pull/1212) ([treydock](https://github.com/treydock))

### Fixed

- Several fixes for sensu\_bonsai\_asset [\#1215](https://github.com/sensu/sensu-puppet/pull/1215) ([treydock](https://github.com/treydock))

### Merged Pull Requests

- Fix release process [\#1216](https://github.com/sensu/sensu-puppet/pull/1216) ([treydock](https://github.com/treydock))

## [v4.5.0](https://github.com/sensu/sensu-puppet/tree/v4.5.0) (2020-02-08)

[Full Changelog](https://github.com/sensu/sensu-puppet/compare/v4.4.1...v4.5.0)

### Added

- Update puppet-strings examples for composite names [\#1211](https://github.com/sensu/sensu-puppet/pull/1211) ([treydock](https://github.com/treydock))
- Support EL8 [\#1208](https://github.com/sensu/sensu-puppet/pull/1208) ([treydock](https://github.com/treydock))
- Remove workaround for sensuctl command json formatting [\#1204](https://github.com/sensu/sensu-puppet/pull/1204) ([treydock](https://github.com/treydock))

## [v4.4.1](https://github.com/sensu/sensu-puppet/tree/v4.4.1) (2020-02-01)

Expand Down Expand Up @@ -38,10 +57,6 @@

[Full Changelog](https://github.com/sensu/sensu-puppet/compare/v4.2.0...v4.2.1)

### Added

- Remove workaround for sensuctl command json formatting [\#1204](https://github.com/sensu/sensu-puppet/pull/1204) ([treydock](https://github.com/treydock))

### Fixed

- Several fixes for sensu\_bonsai\_asset [\#1202](https://github.com/sensu/sensu-puppet/pull/1202) ([treydock](https://github.com/treydock))
Expand Down Expand Up @@ -83,8 +98,9 @@
- Document contact routing and bonsai asset bugfix [\#1194](https://github.com/sensu/sensu-puppet/pull/1194) ([treydock](https://github.com/treydock))
- Support 'sensu-backend init' added in Sensu Go 5.16 [\#1192](https://github.com/sensu/sensu-puppet/pull/1192) ([treydock](https://github.com/treydock))
- Misc test fixes [\#1189](https://github.com/sensu/sensu-puppet/pull/1189) ([treydock](https://github.com/treydock))
- Updates to travis-ci [\#1186](https://github.com/sensu/sensu-puppet/pull/1186) ([treydock](https://github.com/treydock))

### UNCATEGORIZED PRS; GO LABEL THEM
### Merged Pull Requests

- Style [\#1193](https://github.com/sensu/sensu-puppet/pull/1193) ([ghoneycutt](https://github.com/ghoneycutt))
- \(ci\) Update TravisCI configuration for new Slack channel [\#1190](https://github.com/sensu/sensu-puppet/pull/1190) ([ghoneycutt](https://github.com/ghoneycutt))
Expand All @@ -103,7 +119,6 @@

### Added

- Updates to travis-ci [\#1186](https://github.com/sensu/sensu-puppet/pull/1186) ([treydock](https://github.com/treydock))
- Support PDK [\#1184](https://github.com/sensu/sensu-puppet/pull/1184) ([treydock](https://github.com/treydock))
- Update default resources to match Sensu Go defaults [\#1181](https://github.com/sensu/sensu-puppet/pull/1181) ([treydock](https://github.com/treydock))
- Move PostgresConfig to a type [\#1176](https://github.com/sensu/sensu-puppet/pull/1176) ([treydock](https://github.com/treydock))
Expand Down Expand Up @@ -233,22 +248,15 @@
### Added

- Add headers property to sensu\_assets [\#1119](https://github.com/sensu/sensu-puppet/pull/1119) ([treydock](https://github.com/treydock))
- Add ability to run acceptance tests against Sensu-Go CI builds [\#1115](https://github.com/sensu/sensu-puppet/pull/1115) ([treydock](https://github.com/treydock))
- Support listing sensuctl resources using chunk-size [\#1114](https://github.com/sensu/sensu-puppet/pull/1114) ([treydock](https://github.com/treydock))

### Fixed

- Update several usage examples to match Sensu Go docs [\#1117](https://github.com/sensu/sensu-puppet/pull/1117) ([treydock](https://github.com/treydock))
- Regenerate backend test cert to include additional SANs [\#1113](https://github.com/sensu/sensu-puppet/pull/1113) ([treydock](https://github.com/treydock))

## [v3.3.0](https://github.com/sensu/sensu-puppet/tree/v3.3.0) (2019-05-18)

[Full Changelog](https://github.com/sensu/sensu-puppet/compare/v3.2.0...v3.3.0)

### Added

- \(GH-1111\) Remove Ubuntu 14.04 LTS as it is end of life \(EOL\) [\#1112](https://github.com/sensu/sensu-puppet/pull/1112) ([ghoneycutt](https://github.com/ghoneycutt))

## [v3.2.0](https://github.com/sensu/sensu-puppet/tree/v3.2.0) (2019-05-06)

[Full Changelog](https://github.com/sensu/sensu-puppet/compare/v3.1.0...v3.2.0)
Expand Down
1 change: 1 addition & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ The `master` branch is for development against Sensu Go v5.

1. Update version in `metadata.json`
1. Run Rake task to release module: `pdk bundle exec rake release`
1. Update GitHub pages: `pdk bundle exec rake strings:gh_pages:update`
1. Tag the release, such as `git tag -a 'v3.11.0' -m 'v3.11.0'`
1. Push release to upstream master: `git push upstream master`
1. Push tags upstream master: `git push upstream --tags`
163 changes: 153 additions & 10 deletions REFERENCE.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,9 @@ _Private Classes_

**Resource types**

_Public Resource types_

* [`sensu_ad_auth`](#sensu_ad_auth): Manages Sensu AD auth.
* [`sensu_api_validator`](#sensu_api_validator): Verify that a connection can be successfully established between a node and the sensu-backend server. Its primary use is as a precondition t
* [`sensu_api_config`](#sensu_api_config): Abstract type to configure other types
* [`sensu_api_validator`](#sensu_api_validator): **NOTE** This is a private type not intended to be used directly. Verify that a connection can be successfully established between a node an
* [`sensu_asset`](#sensu_asset): Manages Sensu assets
* [`sensu_bonsai_asset`](#sensu_bonsai_asset): Manages Sensu Bonsai assets
* [`sensu_check`](#sensu_check): Manages Sensu checks
Expand All @@ -55,14 +54,10 @@ _Public Resource types_
* [`sensu_role_binding`](#sensu_role_binding): Manages Sensu role bindings
* [`sensu_secret`](#sensu_secret): Manages Sensu Secrets
* [`sensu_secrets_vault_provider`](#sensu_secrets_vault_provider): Manages Sensu Secrets provider
* [`sensu_tessen`](#sensu_tessen): Manages Sensu Tessen
* [`sensu_user`](#sensu_user): Manages Sensu users

_Private Resource types_

* `sensu_api_config`: Abstract type to configure other types
* `sensu_tessen`: Manages Sensu Tessen - This is a private type
* `sensuctl_config`: Abstract type to configure other types
* `sensuctl_configure`: Manages `sensuctl configure`. This is a private type not intended to be used directly.
* [`sensuctl_config`](#sensuctl_config): Abstract type to configure other types
* [`sensuctl_configure`](#sensuctl_configure): Manages 'sensuctl configure'

**Data types**

Expand Down Expand Up @@ -1193,8 +1188,40 @@ namevar

The name of the AD auth.

### sensu_api_config

**NOTE** This is a private type not intended to be used directly.

#### Parameters

The following parameters are available in the `sensu_api_config` type.

##### `name`

namevar

The name of the resource.

##### `url`

Sensu API URL

##### `username`

Sensu API username

##### `password`

Sensu API password

##### `old_password`

Sensu API old password

### sensu_api_validator

**NOTE** This is a private type not intended to be used directly.

Verify that a connection can be successfully established between a node
and the sensu-backend server. Its primary use is as a precondition to
prevent configuration changes from being applied if the sensu_backend
Expand Down Expand Up @@ -3392,6 +3419,36 @@ namevar

The name of the secrets provider.

### sensu_tessen

**NOTE** This is a private type not intended to be used directly.

**Autorequires**:
* `Package[sensu-go-cli]`
* `Service[sensu-backend]`
* `Sensu_configure[puppet]`
* `Sensu_api_validator[sensu]`

#### Properties

The following properties are available in the `sensu_tessen` type.

##### `ensure`

Valid values: present, absent

State of tessen

#### Parameters

The following parameters are available in the `sensu_tessen` type.

##### `name`

namevar

Resource name

### sensu_user

**Autorequires**:
Expand Down Expand Up @@ -3485,6 +3542,92 @@ Path to trusted CA to use with 'sensuctl configure'

Default value: /etc/sensu/ssl/ca.crt

### sensuctl_config

**NOTE** This is a private type not intended to be used directly.

#### Parameters

The following parameters are available in the `sensuctl_config` type.

##### `name`

namevar

The name of the resource.

##### `chunk_size`

sensuctl chunk-size

##### `path`

path to sensuctl

### sensuctl_configure

**NOTE** This is a private type not intended to be used directly.

**Autorequires**:
* `Package[sensu-go-cli]`
* `Service[sensu-backend]`
* `Sensu_api_validator[sensu]`
* `file` - Puppet will autorequire `file` resources defined in `trusted_ca_file` property.

#### Properties

The following properties are available in the `sensuctl_configure` type.

##### `ensure`

Valid values: present, absent

The basic property that the resource should be in.

Default value: present

##### `url`

sensu-backend URL

##### `trusted_ca_file`

Path to trusted CA

Default value: /etc/sensu/ssl/ca.crt

##### `config_format`

Valid values: tabular, json, wrapped-json, yaml

Set configured format for sensuctl

##### `config_namespace`

Set configured namespace for sensuctl

#### Parameters

The following parameters are available in the `sensuctl_configure` type.

##### `name`

namevar

The name of the resource.

##### `username`

Username to use with sensuctl configure

##### `password`

Password to use with sensuctl configure

##### `old_password`

The previous sensuctl password, needed in order to change passwords

## Data types

### Sensu::Backend_URL
Expand Down
4 changes: 2 additions & 2 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ if Bundler.rubygems.find_name('github_changelog_generator').any?
config.max_issues = 100
config.exclude_labels = ["sensu v2","sensu v1"]
config.add_pr_wo_labels = true
config.merge_prefix = "### UNCATEGORIZED PRS; GO LABEL THEM"
config.merge_prefix = "### Merged Pull Requests"
config.configure_sections = {
"Changed" => {
"prefix" => "### Changed",
Expand Down Expand Up @@ -105,4 +105,4 @@ namespace :release do
end

desc "Release new module version"
task :release => [:changelog, :reference, "release:commit", "strings:gh_pages:update"]
task :release => [:changelog, :reference, "release:commit"]
2 changes: 2 additions & 0 deletions examples/contact_routing.pp
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# Sensu Go docs: https://docs.sensu.io/sensu-go/latest/guides/contact-routing/

include sensu::backend

sensu_bonsai_asset { 'sensu/sensu-go-has-contact-filter':
Expand Down
43 changes: 43 additions & 0 deletions examples/email_alerts.pp
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# Sensu Go docs: https://docs.sensu.io/sensu-go/latest/guides/email-handler/

include sensu::backend

sensu_bonsai_asset { 'sensu/sensu-email-handler':
ensure => 'present',
version => 'latest',
rename => 'sensu-email-handler',
}

sensu_filter { 'state_change_only in default':
ensure => 'present',
action => 'allow',
expressions => [
'event.check.occurrences == 1',
],
}

$from = 'YOUR-SENDER@example.com'
$to = 'YOUR-RECIPIENT@example.com'
$server = 'YOUR-SMTP-SERVER.example.com'
$username = 'USERNAME'
$password = 'PASSWORD'
sensu_handler { 'email in default':
type => 'pipe',
command => "sensu-email-handler -f ${from} -t ${to} -s ${server} -u ${username} -p ${password}",
filters => [
'is_incident',
'not_silenced',
'state_change_only',
],
runtime_assets => ['sensu-email-handler'],
}

sensu_check { 'check_cpu':
ensure => 'present',
command => 'check-cpu.rb -w 75 -c 90',
handlers => ['email'],
interval => 30,
publish => true,
subscriptions => ['linux'],
runtime_assets => ['sensu-plugins-cpu-checks','sensu-ruby-runtime'],
}
2 changes: 2 additions & 0 deletions examples/influxdb_handler.pp
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# Sensu Go docs: https://docs.sensu.io/sensu-go/latest/guides/influx-db-metric-handler/

$addr = 'http://influxdb.default.svc.cluster.local:8086'
$db_name = 'sensu'
$user = 'sensu'
Expand Down
Loading