mptcpd
mptcpd copied to clipboard
mptcpize: use systemd overrides instead of editing vendor provided .service
Is your feature request related to a problem? Please describe.
Currently, mptcpize
will modify the vendor provided systemd service file located at /lib/systemd/system/*.service
.
This approach is problematic because that file can and will change when new versions of the package that owns it are installed. The result is that the mptcpize modification to that file is unexpectedly lost.
Describe the solution you'd like systemd provides overrides as a solution to this problem. See https://www.freedesktop.org/software/systemd/man/systemd.unit.html
For example, I suggest that mptcpize enable xyz
creates a file at /etc/systemd/system/apache2.service.d/mptcpize.conf
with these contents:
[Service]
Environment="LD_PRELOAD=/usr/lib64/mptcpize/libmptcpwrap.so"
Furthermore, using the un-versioned library name (libmptcpwrap.so
as opposed to libmptcpwrap.so.0.0.1
) will avoid unexpected breakage when the version changes in the future.
@pabeni FYI
Good idea! I confirm it would be clearer and it would help in case of software update! :-)