stockholm: guess current-{host,user}-name harder

This commit is contained in:
tv 2016-02-04 04:47:58 +01:00
parent 65977c6108
commit 89d6f319d0

View file

@ -1,5 +1,9 @@
{ current-host-name ? abort "current-host-name not defined" { current-host-name ?
, current-user-name ? builtins.getEnv "LOGNAME" let v = builtins.getEnv "HOSTNAME"; in
if v != "" then v else builtins.readFile /proc/sys/kernel/hostname
, current-user-name ?
let v = builtins.getEnv "LOGNAME"; in
if v != "" then v else abort "undefined variable: LOGNAME"
, StrictHostKeyChecking ? "yes" , StrictHostKeyChecking ? "yes"
}@args: }@args: