Skip to content
This repository was archived by the owner on May 15, 2025. It is now read-only.

Commit 409d6e7

Browse files
authored
Merge branch 'master' into master
2 parents bc7f3e9 + 52c8448 commit 409d6e7

File tree

13 files changed

+86
-73
lines changed

13 files changed

+86
-73
lines changed

.fixtures.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
---
22
fixtures:
3-
forge_modules:
4-
concat: "puppetlabs/concat"
5-
stdlib: "puppetlabs/stdlib"
6-
3+
repositories:
4+
concat: 'https://github.com/puppetlabs/puppetlabs-concat.git'
5+
stdlib: 'https://github.com/puppetlabs/puppetlabs-stdlib.git'
76
symlinks:
87
rsyslog: "#{source_dir}"

CHANGELOG.md

Lines changed: 22 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,22 @@ All notable changes to this project will be documented in this file.
44
Each new release typically also includes the latest modulesync defaults.
55
These should not affect the functionality of the module.
66

7+
## [v3.2.0](https://github.com/voxpupuli/puppet-rsyslog/tree/v3.2.0) (2018-06-14)
8+
9+
[Full Changelog](https://github.com/voxpupuli/puppet-rsyslog/compare/v3.1.1...v3.2.0)
10+
11+
**Implemented enhancements:**
12+
13+
- Add the ability to create custom properties with 'set' [\#86](https://github.com/voxpupuli/puppet-rsyslog/pull/86) ([dhollinger](https://github.com/dhollinger))
14+
- Add support to rsyslog::client for providing property\_filters and exp… [\#78](https://github.com/voxpupuli/puppet-rsyslog/pull/78) ([fatmcgav](https://github.com/fatmcgav))
15+
16+
**Merged pull requests:**
17+
18+
- Update code to more cleanly format nested configuration [\#85](https://github.com/voxpupuli/puppet-rsyslog/pull/85) ([dhollinger](https://github.com/dhollinger))
19+
- drop EOL OSs; fix puppet version range [\#83](https://github.com/voxpupuli/puppet-rsyslog/pull/83) ([bastelfreak](https://github.com/bastelfreak))
20+
- use gitrepos in .fixtures.yml [\#82](https://github.com/voxpupuli/puppet-rsyslog/pull/82) ([bastelfreak](https://github.com/bastelfreak))
21+
- Rely on beaker-hostgenerator for docker nodesets [\#79](https://github.com/voxpupuli/puppet-rsyslog/pull/79) ([ekohl](https://github.com/ekohl))
22+
723
## [v3.1.1](https://github.com/voxpupuli/puppet-rsyslog/tree/v3.1.1) (2018-03-29)
824

925
[Full Changelog](https://github.com/voxpupuli/puppet-rsyslog/compare/v3.1.0...v3.1.1)
@@ -24,10 +40,6 @@ These should not affect the functionality of the module.
2440

2541
- Add docker support for lookup\_tables [\#73](https://github.com/voxpupuli/puppet-rsyslog/pull/73) ([dhollinger](https://github.com/dhollinger))
2642

27-
**Merged pull requests:**
28-
29-
- Release 3.0.0 [\#72](https://github.com/voxpupuli/puppet-rsyslog/pull/72) ([dhollinger](https://github.com/dhollinger))
30-
3143
## [v3.0.0](https://github.com/voxpupuli/puppet-rsyslog/tree/v3.0.0) (2018-03-21)
3244

3345
[Full Changelog](https://github.com/voxpupuli/puppet-rsyslog/compare/v2.3.2...v3.0.0)
@@ -42,7 +54,6 @@ These should not affect the functionality of the module.
4254

4355
**Merged pull requests:**
4456

45-
- Re-Release 2.3.2 [\#69](https://github.com/voxpupuli/puppet-rsyslog/pull/69) ([dhollinger](https://github.com/dhollinger))
4657

4758
## [v2.3.2](https://github.com/voxpupuli/puppet-rsyslog/tree/v2.3.2) (2018-03-12)
4859

@@ -51,11 +62,8 @@ These should not affect the functionality of the module.
5162
**Implemented enhancements:**
5263

5364
- Filters require a unique name when used in rulesets. [\#65](https://github.com/voxpupuli/puppet-rsyslog/issues/65)
54-
- Remove unique name requirement for Filters inside of a Ruleset resource [\#66](https://github.com/voxpupuli/puppet-rsyslog/pull/66) ([dhollinger](https://github.com/dhollinger))
55-
56-
**Fixed bugs:**
57-
5865
- Test travis release fix [\#68](https://github.com/voxpupuli/puppet-rsyslog/pull/68) ([dhollinger](https://github.com/dhollinger))
66+
- Remove unique name requirement for Filters inside of a Ruleset resource [\#66](https://github.com/voxpupuli/puppet-rsyslog/pull/66) ([dhollinger](https://github.com/dhollinger))
5967

6068
**Merged pull requests:**
6169

@@ -72,8 +80,6 @@ These should not affect the functionality of the module.
7280

7381
**Merged pull requests:**
7482

75-
- Release 2.3.1 - fixed [\#63](https://github.com/voxpupuli/puppet-rsyslog/pull/63) ([dhollinger](https://github.com/dhollinger))
76-
- Release 2.3.1 [\#62](https://github.com/voxpupuli/puppet-rsyslog/pull/62) ([dhollinger](https://github.com/dhollinger))
7783

7884
## [v2.3.0](https://github.com/voxpupuli/puppet-rsyslog/tree/v2.3.0) (2018-01-24)
7985

@@ -89,7 +95,6 @@ These should not affect the functionality of the module.
8995

9096
**Merged pull requests:**
9197

92-
- Release 2.3.0 [\#57](https://github.com/voxpupuli/puppet-rsyslog/pull/57) ([dhollinger](https://github.com/dhollinger))
9398
- Update documentation around filters [\#56](https://github.com/voxpupuli/puppet-rsyslog/pull/56) ([dhollinger](https://github.com/dhollinger))
9499
- Property filter operators [\#53](https://github.com/voxpupuli/puppet-rsyslog/pull/53) ([dhollinger](https://github.com/dhollinger))
95100

@@ -104,10 +109,8 @@ These should not affect the functionality of the module.
104109

105110
**Merged pull requests:**
106111

107-
- Release 2.2.1 [\#52](https://github.com/voxpupuli/puppet-rsyslog/pull/52) ([dhollinger](https://github.com/dhollinger))
108112
- Set concat order numeric [\#51](https://github.com/voxpupuli/puppet-rsyslog/pull/51) ([dhollinger](https://github.com/dhollinger))
109113
- Updated docs to correctly reflect the priority functionality [\#50](https://github.com/voxpupuli/puppet-rsyslog/pull/50) ([dhollinger](https://github.com/dhollinger))
110-
- release 2.2.0 [\#49](https://github.com/voxpupuli/puppet-rsyslog/pull/49) ([bastelfreak](https://github.com/bastelfreak))
111114

112115
## [v2.2.0](https://github.com/voxpupuli/puppet-rsyslog/tree/v2.2.0) (2018-01-04)
113116

@@ -129,7 +132,6 @@ These should not affect the functionality of the module.
129132

130133
- bump lowest puppet version 4.4.0-\>4.10.9 [\#48](https://github.com/voxpupuli/puppet-rsyslog/pull/48) ([bastelfreak](https://github.com/bastelfreak))
131134
- Add unit and acceptance tests [\#44](https://github.com/voxpupuli/puppet-rsyslog/pull/44) ([dhollinger](https://github.com/dhollinger))
132-
- Release 2.1.0 [\#38](https://github.com/voxpupuli/puppet-rsyslog/pull/38) ([dhollinger](https://github.com/dhollinger))
133135

134136
## [v2.1.0](https://github.com/voxpupuli/puppet-rsyslog/tree/v2.1.0) (2017-12-06)
135137

@@ -149,15 +151,16 @@ These should not affect the functionality of the module.
149151

150152
## [v2.0.0](https://github.com/voxpupuli/puppet-rsyslog/tree/v2.0.0) (2017-12-06)
151153

152-
[Full Changelog](https://github.com/voxpupuli/puppet-rsyslog/compare/1.1.0...v2.0.0)
154+
[Full Changelog](https://github.com/voxpupuli/puppet-rsyslog/compare/v1.1.0...v2.0.0)
153155

154156
**Merged pull requests:**
155157

156-
- Release 2.0.0 [\#36](https://github.com/voxpupuli/puppet-rsyslog/pull/36) ([dhollinger](https://github.com/dhollinger))
157158
- Add additional README.md shields [\#35](https://github.com/voxpupuli/puppet-rsyslog/pull/35) ([dhollinger](https://github.com/dhollinger))
158159
- modulesync 1.5.0 [\#34](https://github.com/voxpupuli/puppet-rsyslog/pull/34) ([dhollinger](https://github.com/dhollinger))
159160

160-
## 1.1.0 (2017-10-17)
161+
## [v1.1.0](https://github.com/voxpupuli/puppet-rsyslog/tree/v1.1.0) (2017-10-17)
162+
163+
[Full Changelog](https://github.com/voxpupuli/puppet-rsyslog/compare/1.1.0...v1.1.0)
161164

162165
* Feature: Added an `external_service` boolean parameter for allowing puppet-rsyslog to manage configs/logs shared with other processes that may be managed by other modules. (https://github.com/crayfishx/puppet-rsyslog/pull/28)
163166

@@ -186,4 +189,4 @@ This release contains many new enhancements and features, and brings the module
186189
* [Fixed the global params config styling](https://github.com/crayfishx/puppet-rsyslog/pull/13)
187190

188191

189-
\* *This Changelog was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)*
192+
\* *This Changelog was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)*

README.md

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -566,7 +566,8 @@ Configures Rsyslog ruleset blocks in rainerscript. There are two elements in the
566566
* `rules` - the actual content that goes inside the ruleset. Currently the following are supported:
567567
* `action` - rsyslog actions defined inside of the ruleset.
568568
* `lookup` - Sets a variable to the results of an rsyslog lookup.
569-
* `set` - Set an rsyslog variable
569+
* `set` - Set an rsyslog variable or property. Property explicitly requires that the set name be a string beginning with `$!`, while a variable can be a plain string or a string starting with `$.`.
570+
* **NOTE: Setting the variable with a string that does NOT begin with `$.` is deprecated and will be removed in the next major release!**
570571
* `call` - call a specific action.
571572
* `exec` - execute the following system command
572573
* `expression_filter` - Filter based on one or more expressions.
@@ -583,10 +584,13 @@ rsyslog::server::rulesets:
583584
queue.size: '10000'
584585
rules:
585586
- set:
586-
rcv_time: 'exec_template("s_rcv_time")'
587+
# Set a Property with a value from a template.
588+
$!rcv_time: 'exec_template("s_rcv_time")'
587589
- set:
588-
utime_gen: 'exec_template("s_unixtime_generated")'
590+
# Set a Variable with a value from a template.
591+
$.utime_gen: 'exec_template("s_unixtime_generated")'
589592
- set:
593+
# Set a Variable using the deprecated method with a value from $uuid
590594
uuid: '$uuid'
591595
- action:
592596
name: utf8-fix

manifests/client.pp

Lines changed: 20 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,29 @@
11
class rsyslog::client (
2-
Optional[Hash] $global_config = {},
3-
Optional[Hash] $legacy_config = {},
4-
Optional[Hash] $actions = {},
5-
Optional[Hash] $inputs = {},
6-
Optional[Hash] $custom_config = {},
7-
Optional[Hash] $modules = {},
8-
Optional[Hash] $lookup_tables = {},
2+
Optional[Hash] $global_config = {},
3+
Optional[Hash] $legacy_config = {},
4+
Optional[Hash] $actions = {},
5+
Optional[Hash] $inputs = {},
6+
Optional[Hash] $custom_config = {},
7+
Optional[Hash] $modules = {},
8+
Optional[Hash] $lookup_tables = {},
9+
Hash $rulesets = {},
10+
Hash $property_filters = {},
11+
Hash $expression_filters = {},
912
) {
1013

1114
include rsyslog
1215

1316
class { 'rsyslog::config':
14-
global_config => $global_config,
15-
legacy_config => $legacy_config,
16-
actions => $actions,
17-
inputs => $inputs,
18-
custom_config => $custom_config,
19-
modules => $modules,
20-
lookup_tables => $lookup_tables,
17+
global_config => $global_config,
18+
legacy_config => $legacy_config,
19+
actions => $actions,
20+
inputs => $inputs,
21+
custom_config => $custom_config,
22+
modules => $modules,
23+
lookup_tables => $lookup_tables,
24+
rulesets => $rulesets,
25+
property_filters => $property_filters,
26+
expression_filters => $expression_filters,
2127
}
2228

2329

metadata.json

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "puppet-rsyslog",
3-
"version": "3.1.2-rc0",
3+
"version": "3.2.1-rc0",
44
"author": "Vox Pupuli",
55
"summary": "Manage rsyslog v8 configuration",
66
"license": "Apache-2.0",
@@ -46,7 +46,6 @@
4646
{
4747
"operatingsystem": "SLES",
4848
"operatingsystemrelease": [
49-
"10",
5049
"11",
5150
"12"
5251
]
@@ -62,12 +61,6 @@
6261
"operatingsystemrelease": [
6362
"9"
6463
]
65-
},
66-
{
67-
"operatingsystem": "Fedora",
68-
"operatingsystemrelease": [
69-
"25"
70-
]
7164
}
7265
],
7366
"dependencies": [
@@ -83,7 +76,7 @@
8376
"requirements": [
8477
{
8578
"name": "puppet",
86-
"version_requirement": ">= 4.10.9 < 6.0.0"
79+
"version_requirement": ">= 4.10.0 < 6.0.0"
8780
}
8881
],
8982
"data_provider": "hiera"

spec/acceptance/expression_filter_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ class { 'rsyslog::server':
3030
end
3131

3232
describe file('/etc/rsyslog.d/50_rsyslog.conf') do
33-
its(:content) { is_expected.to contain('if msg == "test" then {\ncall ruleset\.action\.test\nstop\n\s*}') }
33+
its(:content) { is_expected.to contain('if msg == "test" then {\n call ruleset\.action\.test\n stop\n\s*}') }
3434
end
3535
end
3636
end

spec/acceptance/ruleset_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,6 @@ class { 'rsyslog::server':
3737
describe file('/etc/rsyslog.d/50_rsyslog.conf') do
3838
it { is_expected.to be_file }
3939
it { is_expected.to be_readable }
40-
its(:content) { is_expected.to match(%r{# ruleset_eth0_514_test ruleset\nruleset \(name="ruleset_eth0_514_test"\n\s*queue\.size="10000"\n\) {\n# Property-based Filter\n:msg, contains, "error" {\ncall action\.ruleset\.test\nstop\n\s*}\n\n}}) }
40+
its(:content) { is_expected.to match(%r{# ruleset_eth0_514_test ruleset\nruleset \(name="ruleset_eth0_514_test"\n\s*queue\.size="10000"\n\) {\n# Property-based Filter\n:msg, contains, "error" {\n call action\.ruleset\.test\n stop\n\s*}\n\n}}) }
4141
end
4242
end

spec/classes/client_spec.rb

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,10 @@
1313
inputs: {},
1414
custom_config: {},
1515
modules: {},
16-
lookup_tables: {}
16+
lookup_tables: {},
17+
rulesets: {},
18+
property_filters: {},
19+
expression_filters: {}
1720
)
1821
}
1922
end

spec/defines/component/expression_filter_spec.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,15 +43,15 @@
4343
<<-CONTENT
4444
# myexpressionfilter
4545
if msg == "test" then {
46-
# myaction
46+
# myaction
4747
action(type="omfile"
4848
name="myaction"
4949
dynaFile="remoteSyslog"
5050
)
5151
5252
}
5353
else {
54-
# myaction2
54+
# myaction2
5555
action(type="omfwd"
5656
name="myaction2"
5757
KeepAlive="on"

spec/defines/component/property_filter_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
<<-CONTENT
3333
# mypropertyfilter
3434
:msg, contains, "val" {
35-
# myaction
35+
# myaction
3636
action(type="omfile"
3737
name="myaction"
3838
dynaFile="remoteSyslog"

0 commit comments

Comments
 (0)