diff options
| author | Christian Krinitsin <christian@krinitsin.xyz> | 2025-02-16 17:04:26 +0100 |
|---|---|---|
| committer | Christian Krinitsin <christian@krinitsin.xyz> | 2025-02-16 17:04:26 +0100 |
| commit | 42d3f2e8c9369f24a1e89efdd3b6cbe1f4b10821 (patch) | |
| tree | e04b07e843811d0a739d25b467d9499b3538fc01 /configuration.nix | |
| download | nosix-42d3f2e8c9369f24a1e89efdd3b6cbe1f4b10821.tar.gz nosix-42d3f2e8c9369f24a1e89efdd3b6cbe1f4b10821.zip | |
init
Diffstat (limited to 'configuration.nix')
| -rw-r--r-- | configuration.nix | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/configuration.nix b/configuration.nix new file mode 100644 index 0000000..fd96328 --- /dev/null +++ b/configuration.nix @@ -0,0 +1,39 @@ +{ config, lib, pkgs, ... }: + +{ + imports = + [ # Include the results of the hardware scan. + ./hardware-configuration.nix + ]; + + boot.loader.grub.enable = true; + boot.loader.grub.device = "/dev/vda"; + + networking.hostName = "nixos"; + + time.timeZone = "Europe/Berlin"; + + users.users.admin = { + isNormalUser = true; + extraGroups = [ "wheel" ]; # Enable ‘sudo’ for the user. + openssh.authorizedKeys.keys = [ "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJZxiAIsF13XqqxG0QzGFhT3iLDMsu2snb0wJOPUUq8e chris@deskpin" ]; + }; + + environment.systemPackages = with pkgs; [ + neovim git + openssh + ]; + + services.openssh.enable = true; + services.openssh.settings.PasswordAuthentication = false; + security.sudo.wheelNeedsPassword = false; + + networking.firewall.enable = true; + networking.firewall.allowedTCPPorts = [ 22 ]; + networking.firewall.allowedUDPPorts = [ ]; + + system.copySystemConfiguration = true; + system.stateVersion = "24.11"; + +} + |