summaryrefslogtreecommitdiffstats
path: root/lass/3modules
diff options
context:
space:
mode:
authorlassulus <lassulus@lassul.us>2017-08-01 20:18:38 +0200
committerlassulus <lassulus@lassul.us>2017-08-01 20:48:17 +0200
commit95aef46c56564ce82e3f0e864cc0508e310a0825 (patch)
tree93704ff44dac2eebb5eb061d6e5c367138f79090 /lass/3modules
parentbcd8c5a9661634a53c88029fc9028e1dbf2228b2 (diff)
l statig_nginx: RIP
Diffstat (limited to 'lass/3modules')
-rw-r--r--lass/3modules/static_nginx.nix78
1 files changed, 0 insertions, 78 deletions
diff --git a/lass/3modules/static_nginx.nix b/lass/3modules/static_nginx.nix
deleted file mode 100644
index cd33a2cf1..000000000
--- a/lass/3modules/static_nginx.nix
+++ /dev/null
@@ -1,78 +0,0 @@
-{ config, lib, pkgs, ... }:
-
-with import <stockholm/lib>;
-
-let
- cfg = config.lass.staticPage;
-
- out = {
- options.lass.staticPage = api;
- config = imp;
- };
-
- api = mkOption {
- type = with types; attrsOf (submodule ({ config, ... }: {
- options = {
- domain = mkOption {
- type = str;
- default = config._module.args.name;
- };
- folder = mkOption {
- type = str;
- default = "/srv/http/${config.domain}";
- };
- #sslEnable = mkEnableOption "ssl";
- #certificate = mkOption {
- # type = str;
- #};
- #certificate_key = mkOption {
- # type = str;
- #};
- #ciphers = mkOption {
- # type = str;
- # default = "AES128+EECDH:AES128+EDH";
- #};
- ssl = mkOption {
- type = with types; submodule ({
- options = {
- enable = mkEnableOption "ssl";
- certificate = mkOption {
- type = str;
- };
- certificate_key = mkOption {
- type = str;
- };
- };
- });
- default = {};
- };
- };
- }));
- default = {};
- };
-
- user = config.services.nginx.user;
- group = config.services.nginx.group;
-
- external-ip = config.krebs.build.host.nets.internet.ip4.addr;
-
- imp = {
- krebs.nginx.servers = flip mapAttrs cfg ( name: { domain, folder, ssl, ... }: {
- server-names = [
- "${domain}"
- "www.${domain}"
- ];
- locations = [
- (nameValuePair "/" ''
- root ${folder};
- '')
- (nameValuePair "~ /\\." ''
- deny all;
- '')
- ];
- inherit ssl;
-
- });
- };
-
-in out