meta: format blue/configuration.nix
This commit is contained in:
parent
5500b7f633
commit
c7353452ee
@ -1,13 +1,14 @@
|
|||||||
# Edit this configuration file to define what should be installed on
|
# Edit this configuration file to define what should be installed on
|
||||||
# your system. Help is available in the configuration.nix(5) man page
|
# your system. Help is available in the configuration.nix(5) man page
|
||||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
||||||
|
|
||||||
{ config, pkgs, lib, ... }:
|
|
||||||
{
|
{
|
||||||
imports =
|
config,
|
||||||
[
|
pkgs,
|
||||||
];
|
lib,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
imports = [
|
||||||
|
];
|
||||||
|
|
||||||
system.stateVersion = "23.05";
|
system.stateVersion = "23.05";
|
||||||
system.autoUpgrade.enable = true;
|
system.autoUpgrade.enable = true;
|
||||||
@ -17,13 +18,13 @@
|
|||||||
gc.automatic = true;
|
gc.automatic = true;
|
||||||
gc.options = "--delete-older-than 7d";
|
gc.options = "--delete-older-than 7d";
|
||||||
package = pkgs.nixUnstable;
|
package = pkgs.nixUnstable;
|
||||||
settings.experimental-features = [ "nix-command" "flakes" ];
|
settings.experimental-features = ["nix-command" "flakes"];
|
||||||
};
|
};
|
||||||
|
|
||||||
boot = {
|
boot = {
|
||||||
kernelPackages = pkgs.linuxPackages_latest;
|
kernelPackages = pkgs.linuxPackages_latest;
|
||||||
kernelParams = [ "msr.allow_writes=on" ];
|
kernelParams = ["msr.allow_writes=on"];
|
||||||
supportedFilesystems = [ "btrfs" ];
|
supportedFilesystems = ["btrfs"];
|
||||||
tmpOnTmpfs = true;
|
tmpOnTmpfs = true;
|
||||||
initrd.compressor = "zstd";
|
initrd.compressor = "zstd";
|
||||||
loader.systemd-boot.enable = true;
|
loader.systemd-boot.enable = true;
|
||||||
@ -36,11 +37,13 @@
|
|||||||
allowSimultaneousMultithreading = true;
|
allowSimultaneousMultithreading = true;
|
||||||
sudo.enable = false;
|
sudo.enable = false;
|
||||||
doas.enable = true;
|
doas.enable = true;
|
||||||
doas.extraRules = [{
|
doas.extraRules = [
|
||||||
users = [ "akill" ];
|
{
|
||||||
keepEnv = true;
|
users = ["akill"];
|
||||||
persist = true;
|
keepEnv = true;
|
||||||
}];
|
persist = true;
|
||||||
|
}
|
||||||
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
powerManagement = {
|
powerManagement = {
|
||||||
@ -50,15 +53,16 @@
|
|||||||
networking = {
|
networking = {
|
||||||
firewall.enable = true;
|
firewall.enable = true;
|
||||||
hostName = "blue";
|
hostName = "blue";
|
||||||
nameservers = [ "127.0.0.1" "::1" ];
|
nameservers = ["127.0.0.1" "::1"];
|
||||||
dhcpcd.extraConfig = "nohook resolv.conf";
|
dhcpcd.extraConfig = "nohook resolv.conf";
|
||||||
|
|
||||||
networkmanager = {
|
networkmanager = {
|
||||||
enable = true;
|
enable = true;
|
||||||
dns = "none";
|
dns = "none";
|
||||||
/*wifi.backend = "iwd"; */
|
/*
|
||||||
|
wifi.backend = "iwd";
|
||||||
|
*/
|
||||||
};
|
};
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
time.timeZone = "Europe/Sarajevo";
|
time.timeZone = "Europe/Sarajevo";
|
||||||
@ -72,7 +76,10 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
programs = {
|
programs = {
|
||||||
gnupg.agent = { enable = true; enableSSHSupport = true; };
|
gnupg.agent = {
|
||||||
|
enable = true;
|
||||||
|
enableSSHSupport = true;
|
||||||
|
};
|
||||||
zsh.enable = true;
|
zsh.enable = true;
|
||||||
firejail.enable = true;
|
firejail.enable = true;
|
||||||
adb.enable = true;
|
adb.enable = true;
|
||||||
@ -85,8 +92,8 @@
|
|||||||
services = {
|
services = {
|
||||||
"caps2esc" = {
|
"caps2esc" = {
|
||||||
description = "Intercepts keyboard udev events";
|
description = "Intercepts keyboard udev events";
|
||||||
wants = [ "systemd-udevd.service" ];
|
wants = ["systemd-udevd.service"];
|
||||||
wantedBy = [ "multi-user.target" ];
|
wantedBy = ["multi-user.target"];
|
||||||
serviceConfig.Nice = -20;
|
serviceConfig.Nice = -20;
|
||||||
script = ''
|
script = ''
|
||||||
${pkgs.interception-tools}/bin/intercept \
|
${pkgs.interception-tools}/bin/intercept \
|
||||||
@ -145,7 +152,7 @@
|
|||||||
windowManager.i3.enable = true;
|
windowManager.i3.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
udev.packages = [ pkgs.rtl-sdr pkgs.openhantek6022 ];
|
udev.packages = [pkgs.rtl-sdr pkgs.openhantek6022];
|
||||||
|
|
||||||
tlp = {
|
tlp = {
|
||||||
enable = true;
|
enable = true;
|
||||||
@ -154,34 +161,33 @@
|
|||||||
actkbd = {
|
actkbd = {
|
||||||
enable = true;
|
enable = true;
|
||||||
bindings = [
|
bindings = [
|
||||||
|
|
||||||
{
|
{
|
||||||
keys = [ 113 ];
|
keys = [113];
|
||||||
events = [ "key" ];
|
events = ["key"];
|
||||||
command = "/run/current-system/sw/bin/runuser -l akill -c 'amixer -q set Master toggle'";
|
command = "/run/current-system/sw/bin/runuser -l akill -c 'amixer -q set Master toggle'";
|
||||||
}
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
keys = [ 114 ];
|
keys = [114];
|
||||||
events = [ "key" "rep" ];
|
events = ["key" "rep"];
|
||||||
command = "/run/current-system/sw/bin/runuser -l akill -c 'amixer -q set Master 5%- unmute'";
|
command = "/run/current-system/sw/bin/runuser -l akill -c 'amixer -q set Master 5%- unmute'";
|
||||||
}
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
keys = [ 115 ];
|
keys = [115];
|
||||||
events = [ "key" "rep" ];
|
events = ["key" "rep"];
|
||||||
command = "/run/current-system/sw/bin/runuser -l akill -c 'amixer -q set Master 5%+ unmute'";
|
command = "/run/current-system/sw/bin/runuser -l akill -c 'amixer -q set Master 5%+ unmute'";
|
||||||
}
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
keys = [ 224 ];
|
keys = [224];
|
||||||
events = [ "key" ];
|
events = ["key"];
|
||||||
command = "${pkgs.light}/bin/light -U 5";
|
command = "${pkgs.light}/bin/light -U 5";
|
||||||
}
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
keys = [ 225 ];
|
keys = [225];
|
||||||
events = [ "key" ];
|
events = ["key"];
|
||||||
command = "${pkgs.light}/bin/light -A 5";
|
command = "${pkgs.light}/bin/light -A 5";
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
@ -231,7 +237,7 @@
|
|||||||
allowBitmaps = true;
|
allowBitmaps = true;
|
||||||
useEmbeddedBitmaps = true;
|
useEmbeddedBitmaps = true;
|
||||||
defaultFonts = {
|
defaultFonts = {
|
||||||
monospace = [ "JetBrainsMono" ];
|
monospace = ["JetBrainsMono"];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -300,6 +306,6 @@
|
|||||||
users.users.akill = {
|
users.users.akill = {
|
||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
shell = pkgs.zsh;
|
shell = pkgs.zsh;
|
||||||
extraGroups = [ "wireshark" "kvm" "tty" "audio" "sound" "adbusers" "dialout" ];
|
extraGroups = ["wireshark" "kvm" "tty" "audio" "sound" "adbusers" "dialout"];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user