sincerity.network/nixos/configuration.nix

68 lines
3 KiB
Nix
Raw Permalink Normal View History

2022-09-23 19:08:07 -07:00
# This is your system's configuration file.
# Use this to configure your system environment (it replaces /etc/nixos/configuration.nix)
{ inputs, lib, config, pkgs, ... }: {
imports = [
# Import your generated (nixos-generate-config) hardware configuration
./hardware-configuration.nix
./vault-warden.nix
2022-10-03 01:15:11 -07:00
./book-stack.nix
2022-10-03 01:45:55 -07:00
# ./bonfire.nix
2022-10-02 21:45:56 -07:00
./mumble.nix
2022-09-23 19:08:07 -07:00
];
nix = {
# This will add each flake input as a registry
# To make nix3 commands consistent with your flake
registry = lib.mapAttrs (_: value: { flake = value; }) inputs;
# This will additionally add your inputs to the system's legacy channels
# Making legacy nix commands consistent as well, awesome!
nixPath = lib.mapAttrsToList (key: value: "${key}=${value.to.path}") config.nix.registry;
settings = {
# Enable flakes and new 'nix' command
experimental-features = "nix-command flakes";
# Deduplicate and optimize nix store
auto-optimise-store = true;
};
};
2022-10-03 00:56:42 -07:00
environment.systemPackages = with pkgs; [
2022-10-02 21:45:56 -07:00
git
vim
];
2022-10-03 01:43:13 -07:00
networking.firewall.allowedTCPPorts = [ 80 443 ];
2022-10-02 21:45:56 -07:00
2022-09-23 19:08:07 -07:00
# Remove if you wish to disable unfree packages for your system
nixpkgs.config.allowUnfree = true;
networking.hostName = "sincerity";
2022-09-23 19:08:07 -07:00
users.users = {
infra = {
2022-09-23 19:08:07 -07:00
isNormalUser = true;
openssh.authorizedKeys.keys = [
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDM0Zvei46x/yZl/IeBCq6+IYQQ0avulzVyBysF9cPigZMCybWRV7IEU+E3k9t6JrbdbdGfJkcZIWmsWDdKS8W8mBnZpVoT0ffLynu8JQ/TKdGm4Qv6bgUeKNrGsNv0ZPs2CDaGSLj0oJfRF7Ko10tcLP0vW+yujrh+y6TH/vVzJioaV4TGvtCUpn+wEQah9ROwPQLUUofsSWdnRsDJ/gp37zXWs4l5wyjSKtP3O9RZUP7kBekbSqEgSXiTk0oUQSVqIWl9NDiP6onk/gSOjXsR/JPqsSN/XI/c/yj6gyY0f51Ru2D7iBxuMJIJcWV+rU6coIj+ULcQWLzt/7TI8jq5AOOzI/ll4zbL24Eo84Rz+TP9tvMMhDZ0VaMN22AJ8qQEjc5P09tWKsX7Jg39XelyV1jHXncE4yvIE9F4RSCHzWCeKeXakizQNuzSaxTxIExRFYHjNW5bR6+3MTGwVrEIXU+qML+0yFTR86MT+tdY5AreAJQLwbog79O1NupeXJE= anish@curve"
2022-10-03 00:12:48 -07:00
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDZFLddXLVRgfpqwV1nBAe48Ft7DzLLNxQFmmuBQaH+LvZASzMkTi8WRsAAx5PC7WJXlDlapkBNqqSIqY9eBW8aBW4tw0l8MZ74/0sHB+oKD8vfT0sFRndMUBjYAuWOmxghSXoM5kf1dOyZFDnR77sB2kuuZNR1QGWJ2giUwJyaVF5QhDTbK/rJ1O4I/2O41ycxIG1T/gujvPYjYUUk9NGaQV4Y25Lg+SSeYepYBujiXmn+j2HUjNAsuuyl8O674KaLWb9+SFxEYPDWYLLeLgcnLmzAEdy57k95YWAwnUoXJFrv19B/E8o3Sv5sUhbRH39SsMWN2DS9tV5LQYQ1UW/6BUwDw1tiRsxgTd0tp+PQ5y8q5fF7lO+aSVVfYrjsT+6oaY8Ypi4CZ8uMXnZl4EH0zrpF/VGOWN8voXE/p/SI4REP9Hg7iuLLuK3YiD3w2t2ULfJ6y2S980NSE+n/MbofYVkwR+RzenBh8TqQeV/LvmW/YnoaejF8KEvI+cIvYWk= arch@fedora"
2022-09-23 19:08:07 -07:00
];
extraGroups = [ "wheel" ];
};
};
2022-10-03 00:12:48 -07:00
security.sudo.wheelNeedsPassword = false; # We don't know the password but we still want root
2022-09-23 19:08:07 -07:00
# This setups a SSH server. Very important if you're setting up a headless system.
# Feel free to remove if you don't need it.
services.openssh = {
enable = true;
# Forbid root login through SSH.
permitRootLogin = "no";
# Use keys only. Remove if you want to SSH using password (not recommended)
passwordAuthentication = false;
};
# https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion
system.stateVersion = "22.05";
}