mirror of
https://github.com/genebean/dots.git
synced 2026-03-27 09:27:44 -04:00
More nginx settings
This commit is contained in:
parent
e282662919
commit
f149ed3b1b
1 changed files with 26 additions and 6 deletions
|
|
@ -1,4 +1,7 @@
|
||||||
{ ... }: {
|
{ ... }: let
|
||||||
|
http_port = 8080;
|
||||||
|
https_port = 8444;
|
||||||
|
in {
|
||||||
containers.nginx-proxy = {
|
containers.nginx-proxy = {
|
||||||
autoStart = true;
|
autoStart = true;
|
||||||
privateNetwork = true;
|
privateNetwork = true;
|
||||||
|
|
@ -8,16 +11,33 @@
|
||||||
system.stateVersion = "23.11";
|
system.stateVersion = "23.11";
|
||||||
services.nginx = {
|
services.nginx = {
|
||||||
enable = true;
|
enable = true;
|
||||||
virtualHosts.default.listen = [{
|
recommendedGzipSettings = true;
|
||||||
port = 80;
|
recommendedOptimisation = true;
|
||||||
addr = "0.0.0.0";
|
recommendedProxySettings = true;
|
||||||
}];
|
recommendedTlsSettings = true;
|
||||||
|
|
||||||
|
virtualHosts = {
|
||||||
|
"nix-tester.home.technicalissues.us" = {
|
||||||
|
default = true;
|
||||||
|
listen = [
|
||||||
|
{ port = http_port; addr = "0.0.0.0"; }
|
||||||
|
{ port = https_port; addr = "0.0.0.0"; }
|
||||||
|
];
|
||||||
|
enableACME = true;
|
||||||
|
forceSSL = false;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
security.acme = {
|
||||||
|
acceptTerms = true;
|
||||||
|
defaults.email = "lets-encrypt@technicalissues.us";
|
||||||
};
|
};
|
||||||
|
|
||||||
networking = {
|
networking = {
|
||||||
firewall = {
|
firewall = {
|
||||||
enable = true;
|
enable = true;
|
||||||
allowedTCPPorts = [ 80 ];
|
allowedTCPPorts = [ http_port https_port ];
|
||||||
};
|
};
|
||||||
defaultGateway = "192.168.23.1";
|
defaultGateway = "192.168.23.1";
|
||||||
# Use systemd-resolved inside the container
|
# Use systemd-resolved inside the container
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue