Compare commits

..

No commits in common. "ea0697fc0482f0357abfaf87ce0553999e6b4e41" and "20d705c29729e47bc34fe3606b5b6d83c06ff20c" have entirely different histories.

13 changed files with 76 additions and 75 deletions

View File

@ -1,7 +1,11 @@
# 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, lib, ... }:
let
home-manager = builtins.fetchTarball "https://github.com/nix-community/home-manager/archive/release-23.11.tar.gz";
home-manager = builtins.fetchTarball "https://github.com/nix-community/home-manager/archive/release-23.05.tar.gz";
# python packages to include with python3
python-packages = import ./python-packages.nix;
in
@ -20,14 +24,6 @@ in
./dev
];
# 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?
hardware.bluetooth.enable = true;
hardware.opengl.enable = true;
# for rotation sensors
@ -101,6 +97,9 @@ in
# Configure console keymap
console.keyMap = "de";
# Enable CUPS to print documents.
services.printing.enable = true;
################################################
# __ ___ _ _ _ _ _
# \ \ / (_)_ __| |_ _ _ __ _| (_)___ __ _| |_(_) ___ _ __
@ -114,6 +113,19 @@ in
# - Docker
################################################
# enable rootless docker for more security
virtualisation.docker.rootless = {
enable = true;
setSocketVariable = true;
};
# regulary clean unused docker images
virtualisation.docker.autoPrune.enable = true;
# add user teridax to docker group
users.extraGroups.docker.members = [ "servostar" ];
# KVM
virtualisation.libvirtd.enable = true;
# android container
virtualisation.waydroid.enable = true;
@ -147,14 +159,34 @@ in
# services.xserver.libinput.enable = true;
programs.java.enable = true;
programs.steam = {
enable = true;
remotePlay.openFirewall = true; # Open ports in the firewall for Steam Remote Play
dedicatedServer.openFirewall = true; # Open ports in the firewall for Source Dedicated Server
};
hardware.opengl.driSupport32Bit = true; # Enables support for 32bit libs that steam uses
# Allow unfree packages
nixpkgs.config.allowUnfree = true;
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = (with pkgs; [
(python3.withPackages(python-packages))
conda
virt-manager
distrobox
# Rust toolchain
rustup
libiconv
rust-analyzer
php
php.packages.composer
go
nodejs
@ -207,6 +239,14 @@ in
# Or disable the firewall altogether.
# networking.firewall.enable = false;
# 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.05"; # Did you read the comment?
environment.sessionVariables = rec {
_JAVA_OPTIONS = "-Dawt.useSystemAAFontSettings=lcd";

View File

@ -1,6 +1,5 @@
{
imports = [
./dotnet.nix
./printing.nix
];
}

View File

@ -1,13 +0,0 @@
{ pkgs, config, ... }: {
services.printing.enable = true;
services.avahi.enable = true;
# for a WiFi printer
services.avahi.openFirewall = true;
services.avahi.nssmdns = false; # Use the settings from below
# settings from avahi-daemon.nix where mdns is replaced with mdns4
system.nssModules = pkgs.lib.optional (!config.services.avahi.nssmdns) pkgs.nssmdns;
system.nssDatabases.hosts = with pkgs.lib; optionals (!config.services.avahi.nssmdns) (mkMerge [
(mkBefore [ "mdns4_minimal [NOTFOUND=return]" ]) # before resolve
(mkAfter [ "mdns4" ]) # after dns
]);
}

View File

@ -2,8 +2,6 @@
imports = [
./language-server.nix
./dotnet.nix
./docker-rootless.nix
./platformio.nix
./qemu.nix
];
}

View File

@ -1,9 +0,0 @@
{ pkgs, config, ... }: {
# enable rootless docker for more security
virtualisation.docker.rootless = {
enable = true;
setSocketVariable = true;
};
# regulary clean unused docker images
virtualisation.docker.autoPrune.enable = true;
}

View File

@ -1,6 +0,0 @@
{ pkgs, config, ... }: {
environment.systemPackages = (with pkgs; [
php
php.packages.composer
])
}

View File

@ -1,10 +0,0 @@
{ pkgs, config, ... }: {
# KVM
virtualisation.libvirtd.enable = true;
# programs.virt-manager.enable = true; # after 23.11
# only before 23.11
environment.systemPackages = (with pkgs; [
virt-manager
]);
}

View File

@ -4,6 +4,5 @@
./dvd.nix
./yubikey.nix
./wireguard.nix
./steam.nix
];
}

View File

@ -1,11 +0,0 @@
{ pkgs, config, ... }: {
# Allow unfree packages
nixpkgs.config.allowUnfree = true;
programs.steam = {
enable = true;
remotePlay.openFirewall = true; # Open ports in the firewall for Steam Remote Play
dedicatedServer.openFirewall = true; # Open ports in the firewall for Source Dedicated Server
};
hardware.opengl.driSupport32Bit = true; # Enables support for 32bit libs that steam uses
}

View File

@ -1,10 +1,10 @@
{ pkgs, ... }:
{
fonts = {
enableDefaultPackages = true;
enableDefaultFonts = true;
# extra font packages
packages = with pkgs; [
fonts = with pkgs; [
corefonts
noto-fonts
noto-fonts-cjk
@ -46,4 +46,4 @@
};
};
};
}
}

View File

@ -8,6 +8,9 @@
# Configuration for nix
{ config, pkgs, lib, ... }:
let
unstableTarball = fetchTarball https://github.com/NixOS/nixpkgs-channels/archive/nixos-unstable.tar.gz;
in
{
# cleanup nix store after every build
nix.settings.auto-optimise-store = true;
@ -20,7 +23,12 @@
options = "--delete-older-than 30d";
};
# enable unstable packages
nixpkgs.config = {
allowAliases = true;
packageOverrides = pkgs: with pkgs; {
unstable = import unstableTarball {
config = config.nixpkgs.config;
};
};
};
}

View File

@ -1,3 +0,0 @@
{ pkgs, config, ... }: {
# put your nix module in here!
}

View File

@ -9,6 +9,18 @@
#
# Configuration for user servostar
services.printing.enable = true;
services.avahi.enable = true;
# for a WiFi printer
services.avahi.openFirewall = true;
services.avahi.nssmdns = false; # Use the settings from below
# settings from avahi-daemon.nix where mdns is replaced with mdns4
system.nssModules = pkgs.lib.optional (!config.services.avahi.nssmdns) pkgs.nssmdns;
system.nssDatabases.hosts = with pkgs.lib; optionals (!config.services.avahi.nssmdns) (mkMerge [
(mkBefore [ "mdns4_minimal [NOTFOUND=return]" ]) # before resolve
(mkAfter [ "mdns4" ]) # after dns
]);
# Define a user account. Don't forget to set a password with passwd.
users.users.servostar = {
isNormalUser = true;
@ -22,7 +34,6 @@
"tty"
"uucp"
"plugdev"
"docker"
];
# use zsh
shell = pkgs.zsh;
@ -54,7 +65,7 @@
figlet
cowsay
cmatrix
eza
exa # FIXME: use stable eza version when available
btop
htop
tmux
@ -180,11 +191,9 @@
'';
enableCompletion = true;
enableAutosuggestions = true;
syntaxHighlighting = {
enable = true;
};
enableSyntaxHighlighting = true;
shellAliases = {
ls = "eza --icons";
ls = "exa --icons";
};
history = {
size = 10000;