I wish set the ExecStart of a systemd module explicitly in my configuration.nix
. To avoid confusing the specifics, I’m not going to go into the “why” here, I’ll ask you to trust that I have my reasons.
I tried setting
systemd.services.rsync.serviceConfig.ExecStart = "foo";
But that fails with
The option `systemd.services.rsync.serviceConfig.ExecStart’ has conflicting definition values:
- How do I override to set my own
ExecStart
? - Is it possible to use a similar technique (perhaps overlays) to set an ExecStart based upon configuration values, e.g., setting rsyncd’s ExecStart to
"${pkgs.rsync}/bin/rsync --my-config=${configFile}";