generators: change TimeoutSec=0 to TimeoutSec=infinity

With these settings we intend to turn off timeouts for possibly
interactive/slow commands. The officially documented way to turn off the
time-outs is to setting them to infinity. So far we set them to zero
here though.

This lead to some confusiong, for example #18224. Let's fix this by
uniformly spelling out TimeoutSec=infinity.

This doesn't change behaviour. It just makes our generated files match
what we document, without relying on historic compat support.

Fixes: #18224
This commit is contained in:
Lennart Poettering
2023-06-06 12:38:16 +01:00
committed by Luca Boccassi
parent 6f814d4f5d
commit a9b837aa34
14 changed files with 19 additions and 17 deletions
+2 -1
View File
@@ -562,7 +562,8 @@ static int create_disk(
if (!noauto && !nofail) {
r = write_drop_in(arg_dest, dmname, 40, "device-timeout",
"# Automatically generated by systemd-cryptsetup-generator\n\n"
"[Unit]\nJobTimeoutSec=0");
"[Unit]\n"
"JobTimeoutSec=infinity\n");
if (r < 0)
log_warning_errno(r, "Failed to write device timeout drop-in: %m");
}