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

Various puppet-lint fixes #32

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion manifests/config.pp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
define syslog_ng::config (
$content = '',
$content = undef,
$order = '5'
) {
concat::fragment { "syslog_ng::config ${title}":
Expand Down
2 changes: 1 addition & 1 deletion manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
validate_array($modules)
validate_hash($init_config_hash)

class {'syslog_ng::reload':
class {'::syslog_ng::reload':
syntax_check_before_reloads => $syntax_check_before_reloads
}

Expand Down
3 changes: 2 additions & 1 deletion manifests/params.pp
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
}
$service_name = 'syslog-ng'
$tmp_config_file = '/tmp/syslog-ng.conf.tmp'
$config_file = '/etc/syslog-ng/syslog-ng.conf'
$config_dir = '/etc/syslog-ng'
$config_file = "${config_dir}/syslog-ng.conf"
$config_file_header = "# This file was generated by Puppet's ihrwein-syslog_ng module"
}
2 changes: 1 addition & 1 deletion manifests/reload.pp
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
$syntax_check_before_reloads = true
) {

include syslog_ng::params
include ::syslog_ng::params

$config_file = $::syslog_ng::config_file
$tmp_config_file = $::syslog_ng::params::tmp_config_file
Expand Down
2 changes: 1 addition & 1 deletion manifests/source.pp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
define syslog_ng::source (
$params = []
) {
include syslog_ng::params
include ::syslog_ng::params

$type = 'source'
$id = $title
Expand Down
2 changes: 1 addition & 1 deletion tests/config.pp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include syslog_ng
include ::syslog_ng

syslog_ng::config {'version':
content => '@version: 3.6',
Expand Down
4 changes: 2 additions & 2 deletions tests/default_config.pp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
class syslog_ng::default_config {

syslog_ng::config {"header comment":
syslog_ng::config {'header comment':
content => '
# Default syslog-ng.conf file which collects all local logs into a
# single file called /var/log/messages.
Expand Down Expand Up @@ -38,7 +38,7 @@
{
'type' => 'file',
'options' => [
"/var/log/messages"
'/var/log/messages'
]
}
}
Expand Down
2 changes: 1 addition & 1 deletion tests/destination.pp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include syslog_ng
include ::syslog_ng

syslog_ng::destination { 'd_udp':
params => {
Expand Down
2 changes: 1 addition & 1 deletion tests/filter.pp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include syslog_ng
include ::syslog_ng

syslog_ng::filter {'f_tag_filter':
params => {
Expand Down
2 changes: 1 addition & 1 deletion tests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@
# http://docs.puppetlabs.com/guides/tests_smoke.html
#

class { 'syslog_ng': }
class { '::syslog_ng': }
4 changes: 2 additions & 2 deletions tests/init_2.pp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
# http://docs.puppetlabs.com/guides/tests_smoke.html
#

class { 'syslog_ng':
tmp_config_file => '/tmp/syslog_ng_conf,
class { '::syslog_ng':
tmp_config_file => '/tmp/syslog_ng_conf',
package_name => 'syslog-ng'
}
2 changes: 1 addition & 1 deletion tests/log.pp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include syslog_ng
include ::syslog_ng

syslog_ng::log {'l':
params => [
Expand Down
2 changes: 1 addition & 1 deletion tests/log_02.pp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include syslog_ng
include ::syslog_ng

syslog_ng::log {'l2':
params => [
Expand Down
4 changes: 2 additions & 2 deletions tests/options.pp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
include syslog_ng
include ::syslog_ng

syslog_ng::options { "global_options":
syslog_ng::options { 'global_options':
options => {
'bad_hostname' => "'no'",
'time_reopen' => 10
Expand Down
2 changes: 1 addition & 1 deletion tests/parser.pp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include syslog_ng
include ::syslog_ng

syslog_ng::parser {'p_hostname_segmentation':
params => {
Expand Down
2 changes: 1 addition & 1 deletion tests/rewrite.pp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include syslog_ng
include ::syslog_ng

syslog_ng::rewrite{'r_rewrite_subst':
params => {
Expand Down
22 changes: 11 additions & 11 deletions tests/site.pp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#import 'nodes.pp'

include syslog_ng
include ::syslog_ng

# the header written by this module has order == 1, so the version must be 02
syslog_ng::config {'version':
Expand All @@ -9,19 +9,19 @@
}

syslog_ng::options { 'global_options':
options => {
'bad_hostname' => "'no'"
}
options => {
'bad_hostname' => "'no'"
}
}

syslog_ng::source { 's_gsoc':
params => {
'type' => 'tcp',
'options' => {
'ip' => "'127.0.0.1'",
'port' => 1999
}
}
params => {
'type' => 'tcp',
'options' => {
'ip' => "'127.0.0.1'",
'port' => 1999
}
}
}

syslog_ng::source {'s_external':
Expand Down
2 changes: 1 addition & 1 deletion tests/source.pp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include syslog_ng
include ::syslog_ng

syslog_ng::source { 's_gsoc':
params => {
Expand Down
2 changes: 1 addition & 1 deletion tests/template.pp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include syslog_ng
include ::syslog_ng

syslog_ng::template {'t_demo_filetemplate':
params => [
Expand Down