Nix fmt rfc style (more or less)
This commit is contained in:
parent
e7496c447a
commit
515f098644
146 changed files with 2607 additions and 906 deletions
|
|
@ -7,9 +7,16 @@
|
|||
|
||||
boot = {
|
||||
growPartition = true;
|
||||
kernelParams = [ "console=ttyS0" "panic=1" "boot.panic_on_fail" ];
|
||||
kernelParams = [
|
||||
"console=ttyS0"
|
||||
"panic=1"
|
||||
"boot.panic_on_fail"
|
||||
];
|
||||
initrd.kernelModules = [ "virtio_scsi" ];
|
||||
kernelModules = [ "virtio_pci" "virtio_net" ];
|
||||
kernelModules = [
|
||||
"virtio_pci"
|
||||
"virtio_net"
|
||||
];
|
||||
loader = {
|
||||
grub.device = "/dev/sda";
|
||||
timeout = 0;
|
||||
|
|
@ -24,13 +31,20 @@
|
|||
|
||||
environment = {
|
||||
pathsToLink = [ "/share/zsh" ];
|
||||
systemPackages = [ pkgs.helix pkgs.zellij pkgs.kitty.terminfo ];
|
||||
systemPackages = [
|
||||
pkgs.helix
|
||||
pkgs.zellij
|
||||
pkgs.kitty.terminfo
|
||||
];
|
||||
};
|
||||
|
||||
i18n.defaultLocale = "it_IT.UTF-8";
|
||||
|
||||
programs = {
|
||||
gnupg.agent = { enable = true; enableSSHSupport = true; };
|
||||
gnupg.agent = {
|
||||
enable = true;
|
||||
enableSSHSupport = true;
|
||||
};
|
||||
zsh.enable = true;
|
||||
};
|
||||
|
||||
|
|
@ -65,29 +79,40 @@
|
|||
recommendedTlsSettings = true;
|
||||
virtualHosts =
|
||||
let
|
||||
ssl = { enableACME = true; forceSSL = true; };
|
||||
ssl = {
|
||||
enableACME = true;
|
||||
forceSSL = true;
|
||||
};
|
||||
in
|
||||
{
|
||||
"me.bertof.net" = ssl // {
|
||||
locations."/".extraConfig =
|
||||
"rewrite ^/(.*)$ https://homes.di.unimi.it/berto/$1 redirect ;";
|
||||
locations."/".extraConfig = "rewrite ^/(.*)$ https://homes.di.unimi.it/berto/$1 redirect ;";
|
||||
};
|
||||
"home-assistant.bertof.net" = ssl // {
|
||||
locations."/" = { proxyPass = "http://loki.tsn:8123/"; proxyWebsockets = true; };
|
||||
locations."/" = {
|
||||
proxyPass = "http://loki.tsn:8123/";
|
||||
proxyWebsockets = true;
|
||||
};
|
||||
extraConfig = ''
|
||||
proxy_pass_header Authorization;
|
||||
proxy_buffering off;
|
||||
'';
|
||||
};
|
||||
"s3.bertof.net" = ssl // {
|
||||
locations."/" = { proxyPass = "http://heimdall.tsn:9000/"; proxyWebsockets = true; };
|
||||
locations."/" = {
|
||||
proxyPass = "http://heimdall.tsn:9000/";
|
||||
proxyWebsockets = true;
|
||||
};
|
||||
extraConfig = ''
|
||||
proxy_pass_header Authorization;
|
||||
proxy_buffering off;
|
||||
'';
|
||||
};
|
||||
"hass.bertof.net" = ssl // {
|
||||
locations."/" = { proxyPass = "http://heimdall.tsn:8123/"; proxyWebsockets = true; };
|
||||
locations."/" = {
|
||||
proxyPass = "http://heimdall.tsn:8123/";
|
||||
proxyWebsockets = true;
|
||||
};
|
||||
extraConfig = ''
|
||||
proxy_pass_header Authorization;
|
||||
proxy_buffering off;
|
||||
|
|
@ -120,14 +145,37 @@
|
|||
'';
|
||||
};
|
||||
};
|
||||
"radarr.bertof.net" = ssl // { locations."/" = { proxyPass = "http://heimdall.tsn:7878/"; proxyWebsockets = true; }; };
|
||||
"sonarr.bertof.net" = ssl // { locations."/" = { proxyPass = "http://heimdall.tsn:8989/"; proxyWebsockets = true; }; };
|
||||
"lidarr.bertof.net" = ssl // { locations."/" = { proxyPass = "http://heimdall.tsn:8686/"; proxyWebsockets = true; }; };
|
||||
"radarr.bertof.net" = ssl // {
|
||||
locations."/" = {
|
||||
proxyPass = "http://heimdall.tsn:7878/";
|
||||
proxyWebsockets = true;
|
||||
};
|
||||
};
|
||||
"sonarr.bertof.net" = ssl // {
|
||||
locations."/" = {
|
||||
proxyPass = "http://heimdall.tsn:8989/";
|
||||
proxyWebsockets = true;
|
||||
};
|
||||
};
|
||||
"lidarr.bertof.net" = ssl // {
|
||||
locations."/" = {
|
||||
proxyPass = "http://heimdall.tsn:8686/";
|
||||
proxyWebsockets = true;
|
||||
};
|
||||
};
|
||||
# "ombi.bertof.net" = ssl // { locations."/" = { proxyPass = "http://heimdall.tsn:5000/"; proxyWebsockets = true; }; };
|
||||
"jellyfin.bertof.net" = ssl // { locations."/" = { proxyPass = "http://heimdall.tsn:8096/"; proxyWebsockets = true; }; };
|
||||
"jellyfin.bertof.net" = ssl // {
|
||||
locations."/" = {
|
||||
proxyPass = "http://heimdall.tsn:8096/";
|
||||
proxyWebsockets = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
openssh = { enable = true; openFirewall = true; };
|
||||
openssh = {
|
||||
enable = true;
|
||||
openFirewall = true;
|
||||
};
|
||||
# wgautomesh = {
|
||||
# enable = true;
|
||||
# settings = {
|
||||
|
|
@ -136,7 +184,10 @@
|
|||
# };
|
||||
};
|
||||
|
||||
security.acme = { acceptTerms = true; defaults.email = "filippo.berto95@gmail.com"; };
|
||||
security.acme = {
|
||||
acceptTerms = true;
|
||||
defaults.email = "filippo.berto95@gmail.com";
|
||||
};
|
||||
|
||||
users.users.bertof = {
|
||||
isNormalUser = true;
|
||||
|
|
@ -174,8 +225,15 @@
|
|||
firewall = {
|
||||
enable = true;
|
||||
allowPing = true;
|
||||
allowedTCPPorts = [ 80 443 53 ];
|
||||
allowedUDPPorts = [ 53 51820 ];
|
||||
allowedTCPPorts = [
|
||||
80
|
||||
443
|
||||
53
|
||||
];
|
||||
allowedUDPPorts = [
|
||||
53
|
||||
51820
|
||||
];
|
||||
# interfaces.ens3.allowedTCPPorts = [ 52123 53 ];
|
||||
# interfaces.ens3.allowedUDPPorts = [ 53 ];
|
||||
# extraCommands = ''iptables -t raw -A OUTPUT -p udp -m udp --dport 137 -j CT --helper netbios-ns'';
|
||||
|
|
|
|||
|
|
@ -5,7 +5,13 @@
|
|||
|
||||
boot = {
|
||||
initrd = {
|
||||
availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sd_mod" ];
|
||||
availableKernelModules = [
|
||||
"ata_piix"
|
||||
"uhci_hcd"
|
||||
"virtio_pci"
|
||||
"virtio_scsi"
|
||||
"sd_mod"
|
||||
];
|
||||
kernelModules = [ ];
|
||||
};
|
||||
|
||||
|
|
@ -19,6 +25,9 @@
|
|||
};
|
||||
|
||||
swapDevices = [
|
||||
{ device = "/swapfile"; size = 1024 * 1; }
|
||||
{
|
||||
device = "/swapfile";
|
||||
size = 1024 * 1;
|
||||
}
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,9 +1,14 @@
|
|||
{ pkgs, ... }: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home = {
|
||||
language.base = "it_IT.UTF-8";
|
||||
keyboard = {
|
||||
layout = "it";
|
||||
options = [ "terminate:ctrl_alt_bksp" "compose:rctrl" "grp:menu_toggle" ];
|
||||
options = [
|
||||
"terminate:ctrl_alt_bksp"
|
||||
"compose:rctrl"
|
||||
"grp:menu_toggle"
|
||||
];
|
||||
};
|
||||
packages = builtins.attrValues { inherit (pkgs) nix-prefetch-scripts; };
|
||||
};
|
||||
|
|
|
|||
|
|
@ -1,9 +1,13 @@
|
|||
{ ... }: {
|
||||
{ ... }:
|
||||
{
|
||||
home = {
|
||||
language.base = "it_IT.UTF-8";
|
||||
keyboard = {
|
||||
layout = "it";
|
||||
options = [ "terminate:ctrl_alt_bksp" "compose:rctrl" ];
|
||||
options = [
|
||||
"terminate:ctrl_alt_bksp"
|
||||
"compose:rctrl"
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue