Signed-off-by: Stéphane Graber <stgra...@ubuntu.com> --- config/templates/Makefile.am | 2 ++ config/templates/common.conf.d/Makefile.am | 6 ++++++ config/templates/common.conf.d/README | 6 ++++++ config/templates/common.conf.in | 3 +++ configure.ac | 1 + 5 files changed, 18 insertions(+) create mode 100644 config/templates/common.conf.d/Makefile.am create mode 100644 config/templates/common.conf.d/README
diff --git a/config/templates/Makefile.am b/config/templates/Makefile.am index fdbf9d2..329f919 100644 --- a/config/templates/Makefile.am +++ b/config/templates/Makefile.am @@ -2,6 +2,8 @@ templatesconfigdir=@LXCTEMPLATECONFIG@ EXTRA_DIST = common.seccomp +SUBDIRS = common.conf.d + templatesconfig_DATA = \ archlinux.common.conf \ archlinux.userns.conf \ diff --git a/config/templates/common.conf.d/Makefile.am b/config/templates/common.conf.d/Makefile.am new file mode 100644 index 0000000..b974249 --- /dev/null +++ b/config/templates/common.conf.d/Makefile.am @@ -0,0 +1,6 @@ +templatesconfigdir=@LXCTEMPLATECONFIG@/common.conf.d/ + +EXTRA_DIST = README + +templatesconfig_DATA = \ + README diff --git a/config/templates/common.conf.d/README b/config/templates/common.conf.d/README new file mode 100644 index 0000000..e17a3b3 --- /dev/null +++ b/config/templates/common.conf.d/README @@ -0,0 +1,6 @@ +This directory can be used by packages and users to dump LXC +configuration snippets which will then be used by all containers using +the common.conf configuration file (directlry or indirectly). + +Configuration files must end with the .conf suffix and LXC will include +those in alphabetical order. diff --git a/config/templates/common.conf.in b/config/templates/common.conf.in index f01db08..f22ef0c 100644 --- a/config/templates/common.conf.in +++ b/config/templates/common.conf.in @@ -46,3 +46,6 @@ lxc.cgroup.devices.allow = c 136:* rwm # Blacklist some syscalls which are not safe in privileged # containers lxc.seccomp = @LXCTEMPLATECONFIG@/common.seccomp + +# Lastly, include all the configs from @LXCTEMPLATECONFIG@/common.conf.d/ +lxc.include = @LXCTEMPLATECONFIG@/common.conf.d/ diff --git a/configure.ac b/configure.ac index 09cf9e2..f0605a8 100644 --- a/configure.ac +++ b/configure.ac @@ -627,6 +627,7 @@ AC_CONFIG_FILES([ config/templates/centos.common.conf config/templates/centos.userns.conf config/templates/common.conf + config/templates/common.conf.d/Makefile config/templates/debian.common.conf config/templates/debian.userns.conf config/templates/fedora.common.conf -- 1.9.1 _______________________________________________ lxc-devel mailing list lxc-devel@lists.linuxcontainers.org http://lists.linuxcontainers.org/listinfo/lxc-devel