Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Issue 5189767234846720: Quick-Fix in the context of #765 and #760 (Closed)

Created:
July 10, 2014, 7:59 a.m. by mathias
Modified:
July 16, 2014, 12:29 p.m.
Reviewers:
Wladimir Palant
CC:
christian
Visibility:
Public.

Description

See https://issues.adblockplus.org/ticket/765 - first comment

Patch Set 1 #

Patch Set 2 : See https://issues.adblockplus.org/ticket/765 - first comment #

Total comments: 5
Unified diffs Side-by-side diffs Delta from patch set Stats (+3 lines, -1 line) Patch
M modules/nagios/manifests/server.pp View 1 1 chunk +3 lines, -1 line 3 comments Download

Messages

Total messages: 6
mathias
July 10, 2014, 7:59 a.m. (2014-07-10 07:59:20 UTC) #1
mathias
Sorry, I've just realized that this is not enough yet. We do not only have ...
July 10, 2014, 8:42 a.m. (2014-07-10 08:42:22 UTC) #2
mathias
See https://issues.adblockplus.org/ticket/765 - first comment
July 10, 2014, 9:41 a.m. (2014-07-10 09:41:19 UTC) #3
Wladimir Palant
http://codereview.adblockplus.org/5189767234846720/diff/5741031244955648/modules/nagios/manifests/server.pp File modules/nagios/manifests/server.pp (right): http://codereview.adblockplus.org/5189767234846720/diff/5741031244955648/modules/nagios/manifests/server.pp#newcode95 modules/nagios/manifests/server.pp:95: before => Service['nagios3'] Are you sure we want these ...
July 10, 2014, 10:07 a.m. (2014-07-10 10:07:03 UTC) #4
mathias
http://codereview.adblockplus.org/5189767234846720/diff/5741031244955648/modules/nagios/manifests/server.pp File modules/nagios/manifests/server.pp (right): http://codereview.adblockplus.org/5189767234846720/diff/5741031244955648/modules/nagios/manifests/server.pp#newcode85 modules/nagios/manifests/server.pp:85: file {['/etc/nagios3/conf.d/contacts_nagios2.cfg', Another possible optimization here: We could probably ...
July 10, 2014, 10:22 a.m. (2014-07-10 10:22:17 UTC) #5
Wladimir Palant
July 10, 2014, 10:38 a.m. (2014-07-10 10:38:20 UTC) #6
LGTM

http://codereview.adblockplus.org/5189767234846720/diff/5741031244955648/modu...
File modules/nagios/manifests/server.pp (right):

http://codereview.adblockplus.org/5189767234846720/diff/5741031244955648/modu...
modules/nagios/manifests/server.pp:85: file
{['/etc/nagios3/conf.d/contacts_nagios2.cfg',
On 2014/07/10 10:22:17, matze wrote:
> Another possible optimization here: We could probably perform the deletion
based
> on a pattern (e.g. *_nagios2.cfg).

I don't think Puppet allows pattern matches for file resources. We could use a
shell command instead but that's ugly (especially checking whether that command
needs to run). And we aren't guaranteed that new files added by the package
maintainer will still follow that naming scheme. So I'd be in favor of leaving
things as they are. Note that we are using an LTS Ubuntu release exactly in
order to avoid such issues, at least for a while.

http://codereview.adblockplus.org/5189767234846720/diff/5741031244955648/modu...
modules/nagios/manifests/server.pp:95: before => Service['nagios3']
On 2014/07/10 10:22:17, matze wrote:
> As far as I can see these files are the defaults provided by the package
> manager. Because they conflict with the ones puppet generates for us, they've
> been removed in this directive (before my commit already). All I've tried to
do
> is a) ensure that this is done "early enough" - before the service is started
> the first time - and b) "late enough" - after the package is installed.

Ok, I see now. So the issue was simply these files still being around when
Nagios started...

Powered by Google App Engine
This is Rietveld