chiark / gitweb /
bootchart: Support bootchart.conf.d directories in the usual search paths
authorJosh Triplett <josh@joshtriplett.org>
Sat, 29 Nov 2014 09:06:41 +0000 (01:06 -0800)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Sat, 29 Nov 2014 18:55:32 +0000 (13:55 -0500)
Makefile-man.am
man/bootchart.conf.xml
src/bootchart/bootchart.c
src/bootchart/bootchart.conf

index 2a0d73e05c6cabc5203f8df70123889019ef1cd3..593dc40638e895e2b133d9d6f32b0c6dddd76e52 100644 (file)
@@ -701,8 +701,10 @@ MANPAGES += \
        man/bootchart.conf.5 \
        man/systemd-bootchart.1
 MANPAGES_ALIAS += \
-       #
-
+       man/bootchart.conf.d.5
+man/bootchart.conf.d.5: man/bootchart.conf.5
+man/bootchart.conf.d.html: man/bootchart.conf.html
+       $(html-alias)
 
 endif
 
index 68834c73b7bae1e54ce7df492303a0ce5b45c3b6..a364826bb01d3e9a4cafc8620c7633e75d44276a 100644 (file)
@@ -25,7 +25,8 @@
   along with systemd; If not, see <http://www.gnu.org/licenses/>.
 -->
 
-<refentry id="bootchart.conf" conditional='ENABLE_BOOTCHART'>
+<refentry id="bootchart.conf" conditional='ENABLE_BOOTCHART'
+          xmlns:xi="http://www.w3.org/2001/XInclude">
         <refentryinfo>
                 <title>bootchart.conf</title>
                 <productname>systemd</productname>
 
         <refnamediv>
                 <refname>bootchart.conf</refname>
-                <refpurpose>Boot performance analysis graphing tool configuration file</refpurpose>
+                <refname>bootchart.conf.d</refname>
+                <refpurpose>Boot performance analysis graphing tool configuration files</refpurpose>
         </refnamediv>
 
         <refsynopsisdiv>
                 <para><filename>/etc/systemd/bootchart.conf</filename></para>
+                <para><filename>/etc/systemd/bootchart.conf.d/*.conf</filename></para>
+                <para><filename>/run/systemd/bootchart.conf.d/*.conf</filename></para>
+                <para><filename>/usr/lib/systemd/bootchart.conf.d/*.conf</filename></para>
         </refsynopsisdiv>
 
         <refsect1>
                 <title>Description</title>
 
                 <para>When starting, systemd-bootchart will read the
-                configuration file <filename>bootchart.conf</filename>.
-                This configuration file determines logging parameters and
-                graph output.</para>
-
+                configuration file
+                <filename>/etc/systemd/bootchart.conf</filename>, followed by
+                the files in the <filename>bootchart.conf.d</filename>
+                directories.  These configuration files determine logging
+                parameters and graph output.</para>
         </refsect1>
 
+        <xi:include href="standard-conf.xml" xpointer="confd" />
+        <xi:include href="standard-conf.xml" xpointer="conf" />
+
         <refsect1>
                 <title>Options</title>
 
index 5bb4247c8cbef713d27aaf7d553b87e9e83eb342..0808ba44ea17d401872dd94bd8aca6df009a4ed1 100644 (file)
@@ -125,10 +125,9 @@ static void parse_conf(void) {
                 { NULL, NULL, NULL, 0, NULL }
         };
 
-        config_parse(NULL, BOOTCHART_CONF, NULL,
-                     NULL,
-                     config_item_table_lookup, items,
-                     true, false, true, NULL);
+        config_parse_many(BOOTCHART_CONF,
+                          CONF_DIRS_NULSTR("systemd/bootchart.conf"),
+                          NULL, config_item_table_lookup, items, true, NULL);
 
         if (init != NULL)
                 strscpy(arg_init_path, sizeof(arg_init_path), init);
index d7e0dabe09f1beba604474c46aac6c3deb627032..c73328fde2e885472d40e4ab4d6d605d5f21f5f2 100644 (file)
@@ -5,6 +5,9 @@
 #  the Free Software Foundation; either version 2.1 of the License, or
 #  (at your option) any later version.
 #
+# You can override the directives in this file by creating files in
+# /etc/systemd/bootchart.conf.d/*.conf.
+#
 # See bootchart.conf(5) for details
 
 [Bootchart]