add nginx webserver
This commit is contained in:
@@ -5,10 +5,6 @@
|
||||
default = false;
|
||||
};
|
||||
|
||||
imports = [
|
||||
inputs.authentik-nix.nixosModules.default
|
||||
];
|
||||
|
||||
config = lib.mkIf config.sysconfig.opts.virtualization.authentik.enable {
|
||||
|
||||
sops.templates."authentik.env" = {
|
||||
@@ -33,6 +29,10 @@
|
||||
};
|
||||
};
|
||||
config = {
|
||||
|
||||
imports = [
|
||||
inputs.authentik-nix.nixosModules.default
|
||||
];
|
||||
|
||||
services.authentik = {
|
||||
|
||||
@@ -43,6 +43,8 @@
|
||||
avatars = "initials";
|
||||
};
|
||||
};
|
||||
|
||||
networking.firewall.enable = false;
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
@@ -4,5 +4,6 @@
|
||||
./gitlab
|
||||
./traefik
|
||||
./authentik-nix
|
||||
./nginx
|
||||
];
|
||||
}
|
||||
|
||||
39
system-config/services/containers/nginx/default.nix
Normal file
39
system-config/services/containers/nginx/default.nix
Normal file
@@ -0,0 +1,39 @@
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options.sysconfig.opts.virtualization."blunkall.us".enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.sysconfig.opts.virtualization."blunkall.us".enable {
|
||||
|
||||
containers.blunkall_us = {
|
||||
|
||||
autoStart = true;
|
||||
privateNetwork = true;
|
||||
hostAddress = "192.168.100.10";
|
||||
localAddress = "192.168.100.13";
|
||||
|
||||
bindMounts = {
|
||||
"/var/www/data" = {
|
||||
hostPath = "/ssd1/blunkall_us/data";
|
||||
isReadOnly = false;
|
||||
};
|
||||
};
|
||||
|
||||
config = {
|
||||
|
||||
services.nginx = {
|
||||
enable = true;
|
||||
virtualHosts."blunkall.us" = {
|
||||
enableACME = false;
|
||||
forceSSL = false;
|
||||
root = "/var/www/data";
|
||||
};
|
||||
};
|
||||
|
||||
networking.firewall.allowedTCPPorts = [ 80 ];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -176,7 +176,7 @@
|
||||
services = {
|
||||
#gitlab.loadBalancer.servers = [ { url = "http://192.168.100.12:80"; } ];
|
||||
|
||||
homepage.loadBalancer.servers = [ { url = "http://192.168.100.10:8000"; } ];
|
||||
homepage.loadBalancer.servers = [ { url = "http://192.168.100.13:80"; } ];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user