Nginx: Difference between revisions

update SSL example to include required firewall and acceptTerms configuration for ACME to work
Ibizaman (talk | contribs)
m Update link to list of nginx modules
 
(2 intermediate revisions by 2 users not shown)
Line 287: Line 287:
systemd.services.hedgedoc.serviceConfig.UMask = "0000";
systemd.services.hedgedoc.serviceConfig.UMask = "0000";
</syntaxhighlight>
</syntaxhighlight>
== Modules ==
Nginx can be run with optional modules. You can add them like this:
  services.nginx.package = (pkgs.nginx.override { modules = [
    pkgs.nginxModules.dav
    pkgs.nginxModules.lua
    ...
  ]; });
See [https://github.com/NixOS/nixpkgs/tree/master/pkgs/servers/http/nginx/modules this] for a more comprehensive list of modules available via configuration.
== Let's Encrypt certificates ==
== Let's Encrypt certificates ==


Line 450: Line 460:
== Extra config ==
== Extra config ==


Appart native options, Nix allows to specify verbatim Nginx configuration. Some options are mutually exclusive.
Apart native options, Nix allows to specify verbatim Nginx configuration. Some options are mutually exclusive.


Below table assumes "services.nginx." prefix for all options. These options allows to keep using Nix configuration file while taking advantage of Nginx features which are not representend in options.
Below table assumes "services.nginx." prefix for all options. These options allows to keep using Nix configuration file while taking advantage of Nginx features which are not representend in options.