diff options
author | Franck Bui <fbui@suse.com> | 2023-08-21 12:37:00 +0200 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2023-10-17 18:57:45 +0200 |
commit | 6495361c7d5e8bf640841d1292ef6cfe1ea244cf (patch) | |
tree | 2aa0b18862588ec5c7dee736bef092d94b9f4487 /src/journal-remote | |
parent | Merge pull request #29242 from fbuihuu/update-main-config-file-headers (diff) | |
download | systemd-6495361c7d5e8bf640841d1292ef6cfe1ea244cf.tar.xz systemd-6495361c7d5e8bf640841d1292ef6cfe1ea244cf.zip |
meson: add build option for install path of main config files
This allows distros to install configuration file templates in /usr/lib/systemd
for example.
Currently we install "empty" config files in /etc/systemd/. They serve two
purposes:
- The file contains commented-out values that show the default settings.
- It is easier to edit the right file if it is already there, the user doesn't
have to type in the path correctly, and the basic file structure is already in
place so it's easier to edit.
Things that have happened since this approach was put in place:
- We started supporting drop-ins for config files, and drop-ins are the
recommended way to create local configuration overrides.
- We have systemd-analyze cat-config which takes care of iterating over
all possible locations (/etc, /run, /usr, /usr/local) and figuring out
the right file.
- Because of the first two points, systemd-analyze cat-config is much better,
because it takes care of finding all the drop-ins and figuring out the
precedence. Looking at files manually is still possible of course, but not
very convenient.
The disadvantages of the current approach with "empty" files in /etc:
- We clutter up /etc so it's harder to see what the local configuration actually is.
- If a user edits the file, package updates will not override the file (e.g.
systemd.rpm uses %config(noreplace). This means that the "documented defaults"
will become stale over time, if the user ever edits the main config file.
Thus, I think that it's reasonable to:
- Install the main config file to /usr/lib so that it serves as reference for
syntax and option names and default values and is properly updated on package
upgrades.
- Recommend to users to always use drop-ins for configuration and
systemd-analyze cat-config to view the documentation.
This setting makes this change opt-in.
Fixes #18420.
[zjs: add more text to the description]
Diffstat (limited to 'src/journal-remote')
-rw-r--r-- | src/journal-remote/meson.build | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/journal-remote/meson.build b/src/journal-remote/meson.build index 4251624864..964a251774 100644 --- a/src/journal-remote/meson.build +++ b/src/journal-remote/meson.build @@ -102,7 +102,7 @@ foreach tuple : in_files output: file, command : [jinja2_cmdline, '@INPUT@', '@OUTPUT@'], install : tuple[1], - install_dir : pkgsysconfdir) + install_dir : pkgconfigfiledir) endforeach if conf.get('ENABLE_REMOTE') == 1 and conf.get('HAVE_MICROHTTPD') == 1 |