move sites to their own modules
This commit is contained in:
parent
e83f4ded85
commit
5be0c2ab5b
18 changed files with 707 additions and 654 deletions
28
modules/nixos/services/web/nginx/default.nix
Normal file
28
modules/nixos/services/web/nginx/default.nix
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
{
|
||||
lib,
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with lib.custom; let
|
||||
cfg = config.services.web.nginx;
|
||||
in {
|
||||
options.services.web.nginx = with types; {
|
||||
enable = mkBoolOpt false "Enable NGINX Service";
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
services.nginx = {
|
||||
enable = true;
|
||||
package = pkgs.nginxStable.override {openssl = pkgs.libressl;};
|
||||
recommendedProxySettings = true;
|
||||
virtualHosts = {
|
||||
"node.nyc.zackmyers.io" = {
|
||||
forceSSL = true;
|
||||
enableACME = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue