nixos/networking: fix extraHosts generation
This commit is contained in:
+8
-15
@@ -99,22 +99,15 @@ in
|
|||||||
|
|
||||||
extraHosts =
|
extraHosts =
|
||||||
let
|
let
|
||||||
subdomains = [
|
subdomains = [ "git" ];
|
||||||
""
|
|
||||||
".git"
|
inherit (config.networking) fqdn;
|
||||||
];
|
hosts = [ fqdn ] ++ map (sub: "${sub}.${fqdn}") subdomains;
|
||||||
in
|
in
|
||||||
builtins.foldl' (
|
lib.concatMapStrings (host: ''
|
||||||
hosts-acc: domain-prefix:
|
127.0.0.1 ${host}
|
||||||
let
|
::1 ${host}
|
||||||
host = "${domain-prefix}${config.networking.fqdn}";
|
'') hosts;
|
||||||
in
|
|
||||||
hosts-acc
|
|
||||||
+ ''
|
|
||||||
127.0.0.1 ${host}
|
|
||||||
::1 ${host}
|
|
||||||
''
|
|
||||||
) "" subdomains;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
virtualisation.podman.enable = true;
|
virtualisation.podman.enable = true;
|
||||||
|
|||||||
Reference in New Issue
Block a user