chiark / gitweb /
coredump: Support coredump.conf.d directories in the usual search paths
authorJosh Triplett <josh@joshtriplett.org>
Sat, 29 Nov 2014 09:06:48 +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/coredump.conf.xml
src/journal/coredump.c
src/journal/coredump.conf

index 593dc40638e895e2b133d9d6f32b0c6dddd76e52..01d34087b2aba8f1e5c47ba6e3e07f2806e6e099 100644 (file)
@@ -714,8 +714,10 @@ MANPAGES += \
        man/coredumpctl.1 \
        man/systemd-coredump.8
 MANPAGES_ALIAS += \
        man/coredumpctl.1 \
        man/systemd-coredump.8
 MANPAGES_ALIAS += \
-       #
-
+       man/coredump.conf.d.5
+man/coredump.conf.d.5: man/coredump.conf.5
+man/coredump.conf.d.html: man/coredump.conf.html
+       $(html-alias)
 
 endif
 
 
 endif
 
index 5eb5c5f199cf5564c2cfd95604f25ff2bf14705e..37916f0400d4beb1763418b8348adb28edccc857 100644 (file)
@@ -22,7 +22,8 @@
   along with systemd; If not, see <http://www.gnu.org/licenses/>.
 -->
 
   along with systemd; If not, see <http://www.gnu.org/licenses/>.
 -->
 
-<refentry id="coredump.conf" conditional="ENABLE_COREDUMP">
+<refentry id="coredump.conf" conditional="ENABLE_COREDUMP"
+          xmlns:xi="http://www.w3.org/2001/XInclude">
   <refentryinfo>
     <title>coredump.conf</title>
     <productname>systemd</productname>
   <refentryinfo>
     <title>coredump.conf</title>
     <productname>systemd</productname>
 
   <refnamediv>
     <refname>coredump.conf</refname>
 
   <refnamediv>
     <refname>coredump.conf</refname>
-    <refpurpose>Coredump storage configuration file</refpurpose>
+    <refname>coredump.conf.d</refname>
+    <refpurpose>Coredump storage configuration files</refpurpose>
   </refnamediv>
 
   <refsynopsisdiv>
     <para><filename>/etc/systemd/coredump.conf</filename></para>
   </refnamediv>
 
   <refsynopsisdiv>
     <para><filename>/etc/systemd/coredump.conf</filename></para>
+    <para><filename>/etc/systemd/coredump.conf.d/*.conf</filename></para>
+    <para><filename>/run/systemd/coredump.conf.d/*.conf</filename></para>
+    <para><filename>/usr/lib/systemd/coredump.conf.d/*.conf</filename></para>
   </refsynopsisdiv>
 
   <refsect1>
     <title>Description</title>
 
   </refsynopsisdiv>
 
   <refsect1>
     <title>Description</title>
 
-    <para>This file configures the behaviour of <command>systemd-coredump</command>,
+    <para>These files configure the behaviour of <command>systemd-coredump</command>,
     a handler for core dumps invoked by the kernel.</para>
   </refsect1>
 
     a handler for core dumps invoked by the kernel.</para>
   </refsect1>
 
+  <xi:include href="standard-conf.xml" xpointer="confd" />
+  <xi:include href="standard-conf.xml" xpointer="conf" />
+
   <refsect1>
     <title>Options</title>
 
   <refsect1>
     <title>Options</title>
 
index d889ed1f8f28ef0e95ff5aa1ad404fc40437d269..be45a684e5aadc8f6592b50911ab38daca6c74dd 100644 (file)
@@ -120,10 +120,11 @@ static int parse_config(void) {
                 {}
         };
 
                 {}
         };
 
-        return config_parse(NULL, "/etc/systemd/coredump.conf", NULL,
-                            "Coredump\0",
-                            config_item_table_lookup, items,
-                            false, false, true, NULL);
+        return config_parse_many("/etc/systemd/coredump.conf",
+                                 CONF_DIRS_NULSTR("systemd/coredump.conf"),
+                                 "Coredump\0",
+                                 config_item_table_lookup, items,
+                                 false, NULL);
 }
 
 static int fix_acl(int fd, uid_t uid) {
 }
 
 static int fix_acl(int fd, uid_t uid) {
index 0cc328f549eb84577700cd197a94571d00581a29..0fe9fe801af1f12172b0ed5c5a92ded90ba36a67 100644 (file)
@@ -5,6 +5,9 @@
 #  the Free Software Foundation; either version 2.1 of the License, or
 #  (at your option) any later version.
 #
 #  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/coredump.conf.d/*.conf.
+#
 # See coredump.conf(5) for details
 
 [Coredump]
 # See coredump.conf(5) for details
 
 [Coredump]