mirror of
https://github.com/Swarsel/.dotfiles.git
synced 2026-04-14 21:29:12 +02:00
wip: continue migration
This commit is contained in:
parent
7ce27d5d2f
commit
fa9bd32b0b
129 changed files with 6252 additions and 106 deletions
61
hosds/nixos/x86_64-linux/hintbooth/guests/nginx/default.nix
Normal file
61
hosds/nixos/x86_64-linux/hintbooth/guests/nginx/default.nix
Normal file
|
|
@ -0,0 +1,61 @@
|
|||
{ self, config, lib, minimal, globals, confLib, ... }:
|
||||
let
|
||||
inherit (confLib.static) nginxAccessRules;
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
"${self}/profiles/nixos/microvm"
|
||||
"${self}/modules/nixos"
|
||||
"${self}/modules/nixos/optional/microvm-guest-shares.nix"
|
||||
];
|
||||
|
||||
swarselsystems = {
|
||||
isMicroVM = true;
|
||||
isImpermanence = true;
|
||||
proxyHost = config.node.name;
|
||||
server = {
|
||||
wireguard.interfaces = {
|
||||
wgHome = {
|
||||
isClient = true;
|
||||
serverName = "hintbooth";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
globals.general.homeWebProxy = config.node.name;
|
||||
|
||||
} // lib.optionalAttrs (!minimal) {
|
||||
|
||||
microvm = {
|
||||
mem = 3072 * 1;
|
||||
vcpu = 1;
|
||||
};
|
||||
|
||||
swarselprofiles = {
|
||||
microvm = true;
|
||||
};
|
||||
|
||||
swarselmodules.server = {
|
||||
nginx = true;
|
||||
};
|
||||
|
||||
services.nginx = {
|
||||
upstreams.fritzbox = {
|
||||
servers.${globals.networks.home-lan.hosts.fritzbox.ipv4} = { };
|
||||
};
|
||||
virtualHosts.${globals.services.fritzbox.domain} = {
|
||||
useACMEHost = globals.domains.main;
|
||||
forceSSL = true;
|
||||
acmeRoot = null;
|
||||
locations."/" = {
|
||||
proxyPass = "http://fritzbox";
|
||||
proxyWebsockets = true;
|
||||
};
|
||||
extraConfig = ''
|
||||
proxy_ssl_verify off;
|
||||
'' + nginxAccessRules;
|
||||
};
|
||||
};
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue