Bacula-users

Re: [Bacula-users] Read all config files in a directory

2008-04-28 17:25:49
Subject: Re: [Bacula-users] Read all config files in a directory
From: "Israel Miranda" <programadorlinux AT gmail DOT com>
To: bacula-users AT lists.sourceforge DOT net
Date: Mon, 28 Apr 2008 16:43:33 -0300
Bacula already support a way of doing this.
Since bacula 2.2.0 bacula support inputs from the command line, with the |@ command
I do exacly what you want with the following line in my config:

@|"sh -c 'for f in /etc/bacula/conf.d/*.conf ; do echo @${f} ; done'"

this command make bacula includes every file with the .conf extension within the /etc/bacula/conf.d/ directory.

I learnt that in bacula wiki, you should check it out:
http://wiki.bacula.org/doku.php?id=sample_configs

2008/4/28 Marc Schiffbauer <marc AT schiffbauer DOT net>:
* Hemant Shah schrieb am 28.04.08 um 04:25 Uhr:
> Folks,
>
> Maybe this could be a feature request.
>
> In a config file you can include another config file by specifying @/path/to/file. Is there a way to specify a path to a directory and have bacula daemons read all files in that directory.
>
> This would be similar to specifying config files for logrotate.
>
> Example:
>
> The bacula-dir.conf file would look like:
>
> Director
> {
> }
>
> @/path/to/directory/containing/dir/config/files
>
> If I need to add a client I just create a file in the directory and re-start director and it will read it. I do not have to add include statement in bacula-dir.conf file.


+1

Good Idea!

As a workaround you could have a script which creates your
bacula-dir.conf automatically everytime you create a new sub-config
file.

-Marc

--
****************************************************
*   (morganj): 0 is false and 1 is true, correct?  *
*   (alec_eso): 1, morganj                         *
*   (morganj): bastard.                            *

-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users



--
Meus cumprimentos,

Israel Vinícius Nogueira Miranda
-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
Don't miss this year's exciting event. There's still time to save $100. 
Use priority code J8TL2D2. 
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users