2023-10-27 19:04:55 +02:00
|
|
|
|
# Edit this configuration file to define what should be installed on
|
|
|
|
|
# your system. Help is available in the configuration.nix(5) man page
|
|
|
|
|
# and in the NixOS manual (accessible by running `nixos-help`).
|
|
|
|
|
|
|
|
|
|
{ config, pkgs, ... }:
|
|
|
|
|
|
|
|
|
|
{
|
|
|
|
|
imports =
|
2024-03-11 16:19:31 +01:00
|
|
|
|
[
|
|
|
|
|
# Include the results of the hardware scan.
|
2023-10-27 19:04:55 +02:00
|
|
|
|
./hardware-configuration.nix
|
|
|
|
|
];
|
2024-03-26 09:22:50 +01:00
|
|
|
|
|
|
|
|
|
materus.profile.nixpkgs.enable = true;
|
2023-10-27 19:04:55 +02:00
|
|
|
|
environment.systemPackages = with pkgs; [
|
|
|
|
|
libraspberrypi
|
|
|
|
|
raspberrypi-eeprom
|
|
|
|
|
git
|
2024-03-26 09:22:50 +01:00
|
|
|
|
|
|
|
|
|
p7zip
|
|
|
|
|
unrar
|
|
|
|
|
bzip2
|
|
|
|
|
unzip
|
|
|
|
|
zstd
|
|
|
|
|
xz
|
|
|
|
|
zip
|
|
|
|
|
gzip
|
|
|
|
|
|
2023-10-27 19:04:55 +02:00
|
|
|
|
];
|
|
|
|
|
sound.enable = false;
|
2024-03-11 16:19:31 +01:00
|
|
|
|
boot.tmp.useTmpfs = true;
|
|
|
|
|
services.xserver.enable = false;
|
2023-10-27 19:04:55 +02:00
|
|
|
|
networking.hostName = "waffentrager";
|
2024-03-23 17:56:09 +01:00
|
|
|
|
|
2023-10-27 19:04:55 +02:00
|
|
|
|
services.openssh.enable = true;
|
2024-03-23 17:56:09 +01:00
|
|
|
|
services.openssh.settings.PermitRootLogin = "no";
|
|
|
|
|
|
2023-10-27 19:04:55 +02:00
|
|
|
|
users.users.materus = {
|
|
|
|
|
isNormalUser = true;
|
|
|
|
|
extraGroups = [ "wheel" ];
|
|
|
|
|
openssh.authorizedKeys.keys = [
|
2024-03-11 16:19:31 +01:00
|
|
|
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPEDY+H8Hc/RSLE064AAh8IojvqxPd8BE5gec2aOfYMh materus@podkos.pl"
|
2023-10-27 19:04:55 +02:00
|
|
|
|
];
|
2024-03-21 19:30:54 +01:00
|
|
|
|
hashedPasswordFile = config.sops.secrets."users/materus".path;
|
2023-10-27 19:04:55 +02:00
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
nix = {
|
|
|
|
|
settings = {
|
|
|
|
|
auto-optimise-store = true;
|
|
|
|
|
experimental-features = [ "nix-command" "flakes" "repl-flake" "no-url-literals" ];
|
|
|
|
|
trusted-users = [ "root" "@wheel" ];
|
|
|
|
|
substituters = [
|
|
|
|
|
"https://nix-community.cachix.org"
|
|
|
|
|
"https://cache.nixos.org/"
|
|
|
|
|
"https://nixerus.cachix.org/"
|
|
|
|
|
];
|
2024-03-11 16:19:31 +01:00
|
|
|
|
trusted-public-keys = [ "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=" "nixerus.cachix.org-1:2x7sIG7y1vAoxc8BNRJwsfapZsiX4hIl4aTi9V5ZDdE=" ];
|
2023-10-27 19:04:55 +02:00
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
# Use the extlinux boot loader. (NixOS wants to enable GRUB by default)
|
|
|
|
|
boot.loader.grub.enable = false;
|
|
|
|
|
# Enables the generation of /boot/extlinux/extlinux.conf
|
|
|
|
|
boot.loader.generic-extlinux-compatible.enable = true;
|
|
|
|
|
# networking.hostName = "nixos"; # Define your hostname.
|
|
|
|
|
# Pick only one of the below networking options.
|
|
|
|
|
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
|
|
|
|
|
# networking.networkmanager.enable = true; # Easiest to use and most distros use this by default.
|
|
|
|
|
|
|
|
|
|
# Set your time zone.
|
|
|
|
|
# time.timeZone = "Europe/Amsterdam";
|
|
|
|
|
|
|
|
|
|
# Configure network proxy if necessary
|
|
|
|
|
# networking.proxy.default = "http://user:password@proxy:port/";
|
|
|
|
|
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
|
|
|
|
|
|
|
|
|
|
# Select internationalisation properties.
|
|
|
|
|
# i18n.defaultLocale = "en_US.UTF-8";
|
|
|
|
|
# console = {
|
|
|
|
|
# font = "Lat2-Terminus16";
|
|
|
|
|
# keyMap = "us";
|
|
|
|
|
# useXkbConfig = true; # use xkbOptions in tty.
|
|
|
|
|
# };
|
|
|
|
|
|
|
|
|
|
# Enable the X11 windowing system.
|
|
|
|
|
# services.xserver.enable = true;
|
|
|
|
|
|
|
|
|
|
|
2024-03-11 16:19:31 +01:00
|
|
|
|
|
2023-10-27 19:04:55 +02:00
|
|
|
|
|
|
|
|
|
# Configure keymap in X11
|
|
|
|
|
# services.xserver.layout = "us";
|
|
|
|
|
# services.xserver.xkbOptions = "eurosign:e,caps:escape";
|
|
|
|
|
|
|
|
|
|
# Enable CUPS to print documents.
|
|
|
|
|
# services.printing.enable = true;
|
|
|
|
|
|
|
|
|
|
# Enable sound.
|
|
|
|
|
# sound.enable = true;
|
|
|
|
|
# hardware.pulseaudio.enable = true;
|
|
|
|
|
|
|
|
|
|
# Enable touchpad support (enabled default in most desktopManager).
|
|
|
|
|
# services.xserver.libinput.enable = true;
|
|
|
|
|
|
|
|
|
|
# Define a user account. Don't forget to set a password with ‘passwd’.
|
|
|
|
|
# users.users.alice = {
|
|
|
|
|
# isNormalUser = true;
|
|
|
|
|
# extraGroups = [ "wheel" ]; # Enable ‘sudo’ for the user.
|
|
|
|
|
# packages = with pkgs; [
|
|
|
|
|
# firefox
|
|
|
|
|
# tree
|
|
|
|
|
# ];
|
|
|
|
|
# };
|
|
|
|
|
|
|
|
|
|
# List packages installed in system profile. To search, run:
|
|
|
|
|
# $ nix search wget
|
|
|
|
|
# environment.systemPackages = with pkgs; [
|
|
|
|
|
# vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
|
|
|
|
|
# wget
|
|
|
|
|
# ];
|
|
|
|
|
|
|
|
|
|
# Some programs need SUID wrappers, can be configured further or are
|
|
|
|
|
# started in user sessions.
|
|
|
|
|
# programs.mtr.enable = true;
|
|
|
|
|
# programs.gnupg.agent = {
|
|
|
|
|
# enable = true;
|
|
|
|
|
# enableSSHSupport = true;
|
|
|
|
|
# };
|
|
|
|
|
|
|
|
|
|
# List services that you want to enable:
|
|
|
|
|
|
|
|
|
|
# Enable the OpenSSH daemon.
|
|
|
|
|
# services.openssh.enable = true;
|
|
|
|
|
|
|
|
|
|
# Open ports in the firewall.
|
|
|
|
|
# networking.firewall.allowedTCPPorts = [ ... ];
|
|
|
|
|
# networking.firewall.allowedUDPPorts = [ ... ];
|
|
|
|
|
# Or disable the firewall altogether.
|
|
|
|
|
# networking.firewall.enable = false;
|
|
|
|
|
|
|
|
|
|
# Copy the NixOS configuration file and link it from the resulting system
|
|
|
|
|
# (/run/current-system/configuration.nix). This is useful in case you
|
|
|
|
|
# accidentally delete configuration.nix.
|
|
|
|
|
# system.copySystemConfiguration = true;
|
|
|
|
|
|
|
|
|
|
# This value determines the NixOS release from which the default
|
|
|
|
|
# settings for stateful data, like file locations and database versions
|
|
|
|
|
# on your system were taken. It's perfectly fine and recommended to leave
|
|
|
|
|
# this value at the release version of the first install of this system.
|
|
|
|
|
# Before changing this value read the documentation for this option
|
|
|
|
|
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
|
|
|
|
system.stateVersion = "23.11"; # Did you read the comment?
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|