Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7867cb1809 | ||
|
|
b25ab16bd7 | ||
|
|
02b5b0779c | ||
|
|
0100a58cf1 | ||
|
|
053e998ea1 |
@@ -2,11 +2,11 @@
|
|||||||
# 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, lib, pkgs, ... }:
|
{ config, lib, pkgs, inputs, ... }:
|
||||||
with lib;
|
with lib;
|
||||||
|
|
||||||
let
|
let
|
||||||
unstable = import (fetchTarball "https://github.com/NixOS/nixpkgs/archive/nixpkgs-unstable.tar.gz") { config = { allowUnfree = true; }; };
|
unstable = import inputs.nixpkgs-unstable { inherit (config.nixpkgs) config; };
|
||||||
in
|
in
|
||||||
|
|
||||||
{
|
{
|
||||||
@@ -19,16 +19,8 @@ in
|
|||||||
kernelPackages = mkDefault pkgs.linuxPackages_latest;
|
kernelPackages = mkDefault pkgs.linuxPackages_latest;
|
||||||
|
|
||||||
loader = {
|
loader = {
|
||||||
efi.canTouchEfiVariables = mkDefault true;
|
systemd-boot.enable = true;
|
||||||
grub = {
|
efi.canTouchEfiVariables = true;
|
||||||
enable = mkDefault true;
|
|
||||||
default = mkDefault "saved";
|
|
||||||
device = mkDefault "nodev";
|
|
||||||
extraEntries = mkDefault "GRUB_SAVEDEFAULT=true";
|
|
||||||
efiSupport = mkDefault true;
|
|
||||||
useOSProber = mkDefault true;
|
|
||||||
theme = mkDefault "${pkgs.kdePackages.breeze-grub}/grub/themes/breeze";
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
supportedFilesystems = mkDefault [ "ntfs" ];
|
supportedFilesystems = mkDefault [ "ntfs" ];
|
||||||
};
|
};
|
||||||
@@ -190,6 +182,25 @@ in
|
|||||||
openFirewall = true;
|
openFirewall = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
systemd.sleep.extraConfig = ''
|
||||||
|
AllowSuspend=no
|
||||||
|
AllowHibernation=no
|
||||||
|
AllowSuspendThenHibernate=no
|
||||||
|
AllowHybridSleep=no
|
||||||
|
'';
|
||||||
|
|
||||||
|
services.logind = {
|
||||||
|
lidSwitch = "ignore";
|
||||||
|
lidSwitchExternalPower = "ignore";
|
||||||
|
extraConfig = ''
|
||||||
|
HandlePowerKey=ignore
|
||||||
|
HandleSuspendKey=ignore
|
||||||
|
HandleHibernateKey=ignore
|
||||||
|
HandleLidSwitch=ignore
|
||||||
|
HandleLidSwitchExternalPower=ignore
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
programs.firefox.enable = true;
|
programs.firefox.enable = true;
|
||||||
programs.steam.enable = true;
|
programs.steam.enable = true;
|
||||||
|
|
||||||
@@ -199,19 +210,20 @@ in
|
|||||||
# List packages installed in system profile. To search, run:
|
# List packages installed in system profile. To search, run:
|
||||||
# $ nix search wget
|
# $ nix search wget
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
vim
|
|
||||||
git
|
|
||||||
lazygit
|
|
||||||
lazydocker
|
|
||||||
tmux
|
|
||||||
nixfmt-rfc-style
|
|
||||||
btop
|
btop
|
||||||
nodejs_20
|
|
||||||
uv
|
|
||||||
code-cursor
|
code-cursor
|
||||||
unstable.cursor-cli
|
deskflow
|
||||||
docker
|
docker
|
||||||
docker-compose
|
docker-compose
|
||||||
|
git
|
||||||
|
lazydocker
|
||||||
|
lazygit
|
||||||
|
nixfmt-rfc-style
|
||||||
|
nodejs_20
|
||||||
|
tmux
|
||||||
|
unstable.cursor-cli
|
||||||
|
uv
|
||||||
|
vim
|
||||||
];
|
];
|
||||||
|
|
||||||
# Some programs need SUID wrappers, can be configured further or are
|
# Some programs need SUID wrappers, can be configured further or are
|
||||||
@@ -245,4 +257,7 @@ in
|
|||||||
# Before changing this value read the documentation for this option
|
# Before changing this value read the documentation for this option
|
||||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
||||||
system.stateVersion = "25.05"; # Did you read the comment?
|
system.stateVersion = "25.05"; # Did you read the comment?
|
||||||
|
|
||||||
|
# Enable flakes
|
||||||
|
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
||||||
}
|
}
|
||||||
|
|||||||
18
flake.nix
Normal file
18
flake.nix
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
description = "NixOS configuration";
|
||||||
|
|
||||||
|
inputs = {
|
||||||
|
nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.05";
|
||||||
|
nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
|
||||||
|
};
|
||||||
|
|
||||||
|
outputs = { self, nixpkgs, nixpkgs-unstable, ... }@inputs: {
|
||||||
|
nixosConfigurations.nixos = nixpkgs.lib.nixosSystem {
|
||||||
|
system = "x86_64-linux";
|
||||||
|
specialArgs = { inherit inputs; };
|
||||||
|
modules = [
|
||||||
|
./configuration.nix
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -1,12 +1,12 @@
|
|||||||
- source: lazygit
|
- source: lazygit
|
||||||
target: /home/root/.config/lazygit
|
target: /root/.config/lazygit
|
||||||
delete: true
|
delete: true
|
||||||
- source: lazygit
|
- source: lazygit
|
||||||
target: /home/dave/.config/lazygit
|
target: /home/dave/.config/lazygit
|
||||||
delete: true
|
delete: true
|
||||||
|
|
||||||
- source: .tmux.conf
|
- source: .tmux.conf
|
||||||
target: /home/root/.tmux.conf
|
target: /root/.tmux.conf
|
||||||
delete: true
|
delete: true
|
||||||
- source: .tmux.conf
|
- source: .tmux.conf
|
||||||
target: /home/dave/.tmux.conf
|
target: /home/dave/.tmux.conf
|
||||||
@@ -15,12 +15,15 @@
|
|||||||
- source: configuration.nix
|
- source: configuration.nix
|
||||||
target: /etc/nixos/configuration.nix
|
target: /etc/nixos/configuration.nix
|
||||||
delete: true
|
delete: true
|
||||||
|
- source: flake.nix
|
||||||
|
target: /etc/nixos/flake.nix
|
||||||
|
delete: true
|
||||||
|
|
||||||
- source: sparky.gitconfig
|
- source: sparky.gitconfig
|
||||||
target: /home/dave/.gitconfig
|
target: /home/dave/.gitconfig
|
||||||
delete: true
|
delete: true
|
||||||
- source: sparky.gitconfig
|
- source: sparky.gitconfig
|
||||||
target: /home/root/.gitconfig
|
target: /root/.gitconfig
|
||||||
delete: true
|
delete: true
|
||||||
|
|
||||||
- source: prometheus.yml
|
- source: prometheus.yml
|
||||||
|
|||||||
Reference in New Issue
Block a user