This commit is contained in:
Chris Kruining 2026-03-25 16:26:04 +01:00
parent ac3dac322d
commit a7a1763fe0
No known key found for this signature in database
GPG key ID: EB894A3560CCCAD2
105 changed files with 1152 additions and 1093 deletions

View file

@ -1,6 +0,0 @@
{
imports = [
./networking
./security
];
}

View file

@ -2,10 +2,10 @@
let
inherit (lib) mkDefault;
cfg = config.${namespace}.system.networking;
cfg = config.sneeuwvlok.system.networking;
in
{
options.${namespace}.system.networking = {};
options.sneeuwvlok.system.networking = {};
config = {
systemd.services.NetworkManager-wait-online.enable = false;

View file

@ -1,13 +1,16 @@
{ config, namespace, inputs, ... }:
let
cfg = config.${namespace}.system.security.boot;
in
{
options.${namespace}.system.security.boot = {};
config,
namespace,
inputs,
...
}: let
cfg = config.sneeuwvlok.system.security.boot;
in {
options.sneeuwvlok.system.security.boot = {};
config = {
boot = {
kernelModules = [ "tcp_bbr" ];
kernelModules = ["tcp_bbr"];
kernel.sysctl = {
## TCP hardening
# Prevent bogus ICMP errors from filling up logs.
@ -43,4 +46,4 @@ in
};
};
};
}
}

View file

@ -1,29 +1,28 @@
{ config, namespace, inputs, ... }:
let
cfg = config.${namespace}.system.security;
in
{
imports = [
./boot
./sops
./sudo
];
{...}: {
flake.modules.nixos.sneeuwvlok.system.security = {
config,
namespace,
inputs,
...
}: let
cfg = config.sneeuwvlok.system.security;
in {
options.sneeuwvlok.system.security = {};
options.${namespace}.system.security = {};
config = {
security = {
acme.acceptTerms = true;
polkit.enable = true;
config = {
security = {
acme.acceptTerms = true;
polkit.enable = true;
pam = {
u2f = {
enable = true;
settings.cue = true;
pam = {
u2f = {
enable = true;
settings.cue = true;
};
};
};
};
programs.gnupg.agent.enable = true;
programs.gnupg.agent.enable = true;
};
};
}

View file

@ -1,12 +1,16 @@
{ pkgs, config, namespace, repoRoot, ... }:
let
cfg = config.${namespace}.system.security.sops;
in
{
options.${namespace}.system.security.sops = {};
pkgs,
config,
namespace,
repoRoot,
...
}: let
cfg = config.sneeuwvlok.system.security.sops;
in {
options.sneeuwvlok.system.security.sops = {};
config = {
environment.systemPackages = with pkgs; [ sops ];
environment.systemPackages = with pkgs; [sops];
sops = {
defaultSopsFormat = "yaml";

View file

@ -1,9 +1,9 @@
{ config, namespace, ... }:
let
cfg = config.${namespace}.system.security.sudo;
cfg = config.sneeuwvlok.system.security.sudo;
in
{
options.${namespace}.system.security.sudo = {};
options.sneeuwvlok.system.security.sudo = {};
config = {
security = {