nixfmt rfc style
This commit is contained in:
parent
037b196e94
commit
133d5a69a5
4 changed files with 91 additions and 46 deletions
|
|
@ -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;
|
||||||
|
|
|
||||||
|
|
@ -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";
|
||||||
|
|
||||||
|
|
@ -98,7 +110,7 @@
|
||||||
hyperkitty = {
|
hyperkitty = {
|
||||||
enable = true;
|
enable = true;
|
||||||
};
|
};
|
||||||
serve.enable=true;
|
serve.enable = true;
|
||||||
webHosts = [
|
webHosts = [
|
||||||
"lists.${config.networking.domain}"
|
"lists.${config.networking.domain}"
|
||||||
];
|
];
|
||||||
|
|
@ -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 = {
|
||||||
|
|
@ -144,7 +160,7 @@
|
||||||
enableManageSieve = false;
|
enableManageSieve = false;
|
||||||
enableSubmission = true;
|
enableSubmission = true;
|
||||||
enableSubmissionSsl = true;
|
enableSubmissionSsl = true;
|
||||||
extraVirtualAliases = {};
|
extraVirtualAliases = { };
|
||||||
lmtpSaveToDetailMailbox = "no"; # DOS potential
|
lmtpSaveToDetailMailbox = "no"; # DOS potential
|
||||||
mailboxes = {
|
mailboxes = {
|
||||||
Drafts = {
|
Drafts = {
|
||||||
|
|
@ -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";
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
14
flake.nix
14
flake.nix
|
|
@ -16,7 +16,7 @@
|
||||||
};
|
};
|
||||||
mailserver = {
|
mailserver = {
|
||||||
url = "git+https://gitlab.com/simple-nixos-mailserver/nixos-mailserver?ref=nixos-25.05";
|
url = "git+https://gitlab.com/simple-nixos-mailserver/nixos-mailserver?ref=nixos-25.05";
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.follows = "nixpkgs";
|
nixpkgs.follows = "nixpkgs";
|
||||||
nixpkgs-25_05.follows = "nixpkgs";
|
nixpkgs-25_05.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
@ -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 {
|
||||||
|
|
|
||||||
|
|
@ -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 = [ ];
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue