summaryrefslogtreecommitdiffstats
path: root/krebs/3modules
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2016-07-22 13:06:15 +0200
committertv <tv@krebsco.de>2016-07-22 13:06:41 +0200
commit8b58e6e6e25e38586f3cc8879aa0444d4fdf6f0d (patch)
treed367db83bc182de3cd18c7bf56541ddef7208135 /krebs/3modules
parent1c931a1f45d0c1fa6f0a1f9010f1430eb416e167 (diff)
nginx: use host name and aliases as default server-names
Diffstat (limited to 'krebs/3modules')
-rw-r--r--krebs/3modules/nginx.nix10
1 files changed, 4 insertions, 6 deletions
diff --git a/krebs/3modules/nginx.nix b/krebs/3modules/nginx.nix
index fc7fcca6f..bc32da3b1 100644
--- a/krebs/3modules/nginx.nix
+++ b/krebs/3modules/nginx.nix
@@ -31,12 +31,10 @@ let
options = {
server-names = mkOption {
type = with types; listOf str;
- # TODO use identity
- default = [
- "${config.networking.hostName}"
- "${config.networking.hostName}.r"
- "${config.networking.hostName}.retiolum"
- ];
+ default =
+ [config.krebs.build.host.name] ++
+ concatMap (getAttr "aliases")
+ (attrValues config.krebs.build.host.nets);
};
listen = mkOption {
type = with types; either str (listOf str);