Add file trigger on /usr/lib/sysctl.d to apply new configuration
As discussed in Debian bug #1088203, sysctl configuration files should be
applied on installation and upgrade. Add a file trigger to make this happen
by running sysctl --system, subject to certain conditions.
The conditions are:
- The init system must not be systemd; it will be adding its own file trigger and we don't want to do the same thing again.
-
/proc/sysmust be available. - We must not be running in a chroot, as we would then wrongly override the outer system.
- We must not be running in a container, as many sysctls will not be writable and we don't know how to handle that.
Closes: #1088203