nix/modules/security.nix
2024-02-12 11:49:35 +01:00

20 lines
485 B
Nix

{ config, lib, ... }: {
security.polkit.enable = true;
# rtkit is optional but recommended
security.rtkit.enable = true;
networking.firewall.enable = true;
} // (lib.mkIf (lib.elem "sway" config.bchmnn.gui.flavour) {
# TODO workaround to get swaylock accepting pw
# https://github.com/NixOS/nixpkgs/issues/158025
security.pam.services.swaylock = { };
}) // (lib.mkIf (config.bchmnn.devenv.enable) {
networking.firewall = {
allowedTCPPorts = [ 3000 ];
};
})