- edited description
Monit includes files even if they are already included
Dear Monit Team,
I have discovered a minor inconvenience regarding the include statement. Assume I have /etc/master.monitrc and I want to say:
#!
include *.monitrc
in it. (So that I could include other .monitrc files next to my "main" configuration file.) Now Monit will keep including the same file into itself recursively until it reaches the limit of the included files, since the pattern matches the monitrc itself that has the include statement.
Couldn't you please make your lexer just skip the "caller" monitrc itself when iterating over the results of glob() in https://bitbucket.org/tildeslash/monit/src/c4016c00ae1ddddeb2a4cff7387bcda4e660de20/src/l.l?at=master&fileviewer=file-view-default#l.l-896 .
Thanks a lot.
P.S.: I know that is very easy to come around this one, e.g. using a separate subdir for "include" files, but I think fixing this would make this "include" feature more fool-proof. :)
Cheers, Gyuri
Comments (3)
-
reporter -
repo owner - changed status to resolved
Fixed: Issue
#270: The include statement now skips recursive inclusion of files, which were included already.→ <<cset 94f6e3ef3556>>
-
repo owner - removed version
Removing version: 5.15 (automated comment)
- Log in to comment