nixfmt rfc style

This commit is contained in:
goeranh 2025-05-26 11:57:29 +02:00
parent 037b196e94
commit 133d5a69a5
No known key found for this signature in database
4 changed files with 91 additions and 46 deletions

View file

@ -1,4 +1,10 @@
{ config, lib, pkgs, ... }: { {
config,
lib,
pkgs,
...
}:
{
users.groups.authentik = { }; users.groups.authentik = { };
users.users.authentik = { users.users.authentik = {
isSystemUser = true; isSystemUser = true;

View file

@ -1,19 +1,28 @@
{ config, lib, pkgs, ... }: {
config,
lib,
pkgs,
...
}:
{ {
imports = imports = [
[
./hardware-configuration.nix ./hardware-configuration.nix
./authentik.nix ./authentik.nix
]; ];
security.pam.loginLimits = [{ security.pam.loginLimits = [
{
domain = "*"; domain = "*";
type = "soft"; type = "soft";
item = "nofile"; item = "nofile";
value = "8192"; value = "8192";
}]; }
nix.settings.experimental-features = [ "nix-command" "flakes" ]; ];
nix.settings.experimental-features = [
"nix-command"
"flakes"
];
nix.settings.trusted-users = [ "administration" ]; nix.settings.trusted-users = [ "administration" ];
nix.settings.download-buffer-size = 6710886400; nix.settings.download-buffer-size = 6710886400;
# boot.loader.grub.enable = true; # boot.loader.grub.enable = true;
@ -39,7 +48,10 @@
} }
]; ];
networking.defaultGateway.address = "172.31.1.1"; networking.defaultGateway.address = "172.31.1.1";
networking.nameservers = [ "9.9.9.9" "1.1.1.1" ]; networking.nameservers = [
"9.9.9.9"
"1.1.1.1"
];
time.timeZone = "Europe/Berlin"; time.timeZone = "Europe/Berlin";
@ -118,7 +130,11 @@
mailserver = { mailserver = {
enable = true; enable = true;
fqdn = "mail.${config.networking.domain}"; fqdn = "mail.${config.networking.domain}";
domains = [ "${config.networking.domain}" "lists.${config.networking.domain}" "mail.${config.networking.domain}" ]; domains = [
"${config.networking.domain}"
"lists.${config.networking.domain}"
"mail.${config.networking.domain}"
];
ldap = { ldap = {
enable = true; enable = true;
bind = { bind = {
@ -172,14 +188,17 @@
services.dovecot2.mailLocation = lib.mkForce "maildir:/var/vmail/%n"; services.dovecot2.mailLocation = lib.mkForce "maildir:/var/vmail/%n";
# services.postfix.relayHost = "141.56.51.14"; # services.postfix.relayHost = "141.56.51.14";
# virtualisation.docker.enable = true; # virtualisation.docker.enable = true;
security.acme.acceptTerms = true; security.acme.acceptTerms = true;
security.acme.defaults.email = "cert@stura.htw-dresden.de"; security.acme.defaults.email = "cert@stura.htw-dresden.de";
networking.firewall.allowedTCPPorts = [ 25 80 443 597 ]; networking.firewall.allowedTCPPorts = [
25
80
443
597
];
system.stateVersion = "24.11"; system.stateVersion = "24.11";
} }

View file

@ -28,8 +28,16 @@ inputs = {
}; };
}; };
outputs = { self, nixpkgs, authentik, mailserver, disko }: { outputs =
formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.nixpkgs-fmt; {
self,
nixpkgs,
authentik,
mailserver,
disko,
}:
{
formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.nixfmt-rfc-style;
nixosConfigurations = { nixosConfigurations = {
authentik = nixpkgs.lib.nixosSystem { authentik = nixpkgs.lib.nixosSystem {

View file

@ -1,15 +1,27 @@
# Do not modify this file! It was generated by nixos-generate-config # Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes # and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead. # to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }: {
config,
lib,
pkgs,
modulesPath,
...
}:
{ {
imports = imports = [
[
(modulesPath + "/profiles/qemu-guest.nix") (modulesPath + "/profiles/qemu-guest.nix")
]; ];
boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" ]; boot.initrd.availableKernelModules = [
"ata_piix"
"uhci_hcd"
"virtio_pci"
"virtio_scsi"
"sd_mod"
"sr_mod"
];
boot.initrd.kernelModules = [ ]; boot.initrd.kernelModules = [ ];
boot.kernelModules = [ ]; boot.kernelModules = [ ];
boot.extraModulePackages = [ ]; boot.extraModulePackages = [ ];