20 lines
417 B
Nix
20 lines
417 B
Nix
{ config, ... }:
|
|
|
|
let
|
|
inherit (config.networking) ports;
|
|
in
|
|
{
|
|
services.nginx = {
|
|
enable = true;
|
|
defaultHTTPListenPort = ports.nginx-http.tcp;
|
|
defaultSSLListenPort = ports.nginx-https.tcp;
|
|
recommendedGzipSettings = true;
|
|
recommendedOptimisation = true;
|
|
recommendedProxySettings = true;
|
|
recommendedTlsSettings = true;
|
|
};
|
|
networking.firewall.allowedTCPPorts = [
|
|
80
|
|
443
|
|
];
|
|
}
|