mirror of
https://github.com/zulip/zulip.git
synced 2025-11-16 20:02:15 +00:00
puppet: Fix puppet-lint warnings in various manifests.
Apparently, `puppet-lint` on Ubuntu trusty throws warnings for certain quoting patterns that are OK in modern `puppet-lint`. I believe the old Zulip code was actually correct (i.e. the old `puppet-lint` implementation was the problem), but it seems worth changing anyway to suppress the warnings. We also exclude more of puppet-apt from linting, since it's third-party code.
This commit is contained in:
@@ -17,7 +17,7 @@ class zulip::redis {
|
||||
}
|
||||
|
||||
exec { 'rediscleanup':
|
||||
onlyif => "echo '80a4cee76bac751576c3db8916fc50a6ea319428 /etc/redis/redis.conf' | sha1sum -c",
|
||||
onlyif => 'echo "80a4cee76bac751576c3db8916fc50a6ea319428 /etc/redis/redis.conf" | sha1sum -c',
|
||||
command => 'head -n-3 /etc/redis/redis.conf | sponge /etc/redis/redis.conf',
|
||||
}
|
||||
|
||||
|
||||
@@ -45,7 +45,7 @@ class zulip::supervisor {
|
||||
# We use supervisor[d] as the pattern so the bash/grep commands don't match.
|
||||
hasrestart => true,
|
||||
# lint:ignore:140chars
|
||||
restart => "bash -c 'if pgrep -f supervisor[d] >/dev/null; then supervisorctl reread && supervisorctl update; else /etc/init.d/supervisor start; fi'"
|
||||
restart => 'bash -c "if pgrep -f supervisor[d] >/dev/null; then supervisorctl reread && supervisorctl update; else /etc/init.d/supervisor start; fi"'
|
||||
# lint:endignore
|
||||
}
|
||||
}
|
||||
|
||||
@@ -126,12 +126,12 @@ class zulip_ops::nagios {
|
||||
|
||||
exec { 'fix_nagios_permissions':
|
||||
command => 'dpkg-statoverride --update --add nagios www-data 2710 /var/lib/nagios3/rw',
|
||||
unless => "bash -c 'ls -ld /var/lib/nagios3/rw | grep ^drwx--s--- -q'",
|
||||
unless => 'bash -c "ls -ld /var/lib/nagios3/rw | grep ^drwx--s--- -q"',
|
||||
notify => Service['nagios3'],
|
||||
}
|
||||
exec { 'fix_nagios_permissions2':
|
||||
command => 'dpkg-statoverride --update --add nagios nagios 751 /var/lib/nagios3',
|
||||
unless => "bash -c 'ls -ld /var/lib/nagios3 | grep ^drwxr-x--x -q'",
|
||||
unless => 'bash -c "ls -ld /var/lib/nagios3 | grep ^drwxr-x--x -q"',
|
||||
notify => Service['nagios3'],
|
||||
}
|
||||
|
||||
|
||||
@@ -5,6 +5,7 @@ EXCLUDED_FILES = [
|
||||
"puppet/apt/README.md",
|
||||
"puppet/apt/manifests/backports.pp",
|
||||
"puppet/apt/manifests/params.pp",
|
||||
"puppet/apt/manifests/release.pp",
|
||||
"puppet/apt/manifests/unattended_upgrades.pp",
|
||||
"puppet/stdlib/tests/file_line.pp",
|
||||
"static/third",
|
||||
|
||||
Reference in New Issue
Block a user