mirror of
https://forgejo.merr.is/annika/nixos.git
synced 2025-12-12 13:03:28 -05:00
A bunch of new structure changes.
This commit is contained in:
parent
1f29ea79b4
commit
634a129840
3 changed files with 102 additions and 55 deletions
80
flake.nix
80
flake.nix
|
|
@ -4,59 +4,55 @@
|
||||||
inputs = {
|
inputs = {
|
||||||
# nixpkgs.url = "github:auxolotl/nixpkgs/nixos-unstable";
|
# nixpkgs.url = "github:auxolotl/nixpkgs/nixos-unstable";
|
||||||
|
|
||||||
lix = {
|
lix = {
|
||||||
url = "git+https://git@git.lix.systems/lix-project/lix?ref=refs/tags/2.90-beta.1";
|
url = "git+https://git@git.lix.systems/lix-project/lix?ref=refs/tags/2.90-beta.1";
|
||||||
flake = false;
|
flake = false;
|
||||||
};
|
};
|
||||||
lix-module = {
|
lix-module = {
|
||||||
url = "git+https://git.lix.systems/lix-project/nixos-module";
|
url = "git+https://git.lix.systems/lix-project/nixos-module";
|
||||||
inputs.lix.follows = "lix";
|
inputs.lix.follows = "lix";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
home-manager = {
|
home-manager = {
|
||||||
url = "github:nix-community/home-manager";
|
url = "github:nix-community/home-manager";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
sops-nix = {
|
sops-nix = {
|
||||||
url = "github:Mic92/sops-nix";
|
url = "github:Mic92/sops-nix";
|
||||||
};
|
};
|
||||||
|
|
||||||
catppuccin-vsc = {
|
catppuccin-vsc = {
|
||||||
url = "https://flakehub.com/f/catppuccin/vscode/*.tar.gz";
|
url = "https://flakehub.com/f/catppuccin/vscode/*.tar.gz";
|
||||||
};
|
};
|
||||||
|
|
||||||
solaar = {
|
solaar = {
|
||||||
url = "github:Svenum/Solaar-Flake/latest";
|
url = "github:Svenum/Solaar-Flake/latest";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = { self, nixpkgs, lix-module, solaar, ... }@inputs:
|
outputs = { self, nixpkgs, lix-module, solaar, ... }@inputs:
|
||||||
let
|
let
|
||||||
system = "x86_64";
|
system = "x86_64";
|
||||||
in {
|
globals = rec {
|
||||||
nixosConfigurations = {
|
user = "annika";
|
||||||
default = nixpkgs.lib.nixosSystem {
|
fullName = "Annika Merris";
|
||||||
specialArgs = {inherit inputs;};
|
gitName = fullName;
|
||||||
modules = [
|
gitEmail = "me@annikamerris.com";
|
||||||
./hosts/default/configuration.nix
|
nixfilesRepo = "ssh://git@forgejo.local.merr.is:2222/annika/nixos2.git";
|
||||||
inputs.home-manager.nixosModules.default
|
};
|
||||||
inputs.sops-nix.nixosModules.sops
|
in
|
||||||
lix-module.nixosModules.default
|
{
|
||||||
];
|
nixosConfigurations = {
|
||||||
};
|
kim = import ./hosts/kim {
|
||||||
kim = nixpkgs.lib.nixosSystem {
|
inherit inputs globals overlays;
|
||||||
specialArgs = {inherit inputs;};
|
};
|
||||||
modules = [
|
};
|
||||||
./hosts/kim/configuration.nix
|
|
||||||
inputs.home-manager.nixosModules.default
|
homeConfigurations = {
|
||||||
inputs.sops-nix.nixosModules.sops
|
kim = nixosConfigurations.kim.config.home-manager.users.${globals.user}.home;
|
||||||
lix-module.nixosModules.default
|
|
||||||
solaar.nixosModules.default
|
|
||||||
];
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -5,13 +5,14 @@
|
||||||
inputs.sops-nix.homeManagerModules.sops
|
inputs.sops-nix.homeManagerModules.sops
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# Let Home Manager install and manage itself.
|
||||||
|
programs.home-manager.enable = true;
|
||||||
|
|
||||||
# Configure secrets stuff
|
# Configure secrets stuff
|
||||||
sops = {
|
sops = {
|
||||||
defaultSopsFile = ../../secrets/secrets.yaml;
|
defaultSopsFile = ../../secrets/secrets.yaml;
|
||||||
defaultSopsFormat = "yaml";
|
defaultSopsFormat = "yaml";
|
||||||
age.keyFile = "/home/annika/.config/sops/age/keys.txt";
|
age.keyFile = "/home/annika/.config/sops/age/keys.txt";
|
||||||
|
|
||||||
secrets."spotifyd/settings/global/password" = { };
|
|
||||||
};
|
};
|
||||||
|
|
||||||
nixpkgs.config.allowUnfree = true;
|
nixpkgs.config.allowUnfree = true;
|
||||||
|
|
@ -20,15 +21,6 @@
|
||||||
home.username = "annika";
|
home.username = "annika";
|
||||||
home.homeDirectory = "/home/annika";
|
home.homeDirectory = "/home/annika";
|
||||||
|
|
||||||
# This value determines the Home Manager release that your configuration is
|
|
||||||
# compatible with. This helps avoid breakage when a new Home Manager release
|
|
||||||
# introduces backwards incompatible changes.
|
|
||||||
#
|
|
||||||
# You should not change this value, even if you update Home Manager. If you do
|
|
||||||
# want to update the value, then make sure to first check the Home Manager
|
|
||||||
# release notes.
|
|
||||||
home.stateVersion = "23.11"; # Please read the comment before changing.
|
|
||||||
|
|
||||||
# The home.packages option allows you to install Nix packages into your
|
# The home.packages option allows you to install Nix packages into your
|
||||||
# environment.
|
# environment.
|
||||||
home.packages = [
|
home.packages = [
|
||||||
|
|
@ -121,6 +113,12 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
# Let Home Manager install and manage itself.
|
# This value determines the Home Manager release that your configuration is
|
||||||
programs.home-manager.enable = true;
|
# compatible with. This helps avoid breakage when a new Home Manager release
|
||||||
|
# introduces backwards incompatible changes.
|
||||||
|
#
|
||||||
|
# You should not change this value, even if you update Home Manager. If you do
|
||||||
|
# want to update the value, then make sure to first check the Home Manager
|
||||||
|
# release notes.
|
||||||
|
home.stateVersion = "23.11"; # Please read the comment before changing.
|
||||||
}
|
}
|
||||||
|
|
|
||||||
53
hosts/kim/default.nix
Normal file
53
hosts/kim/default.nix
Normal file
|
|
@ -0,0 +1,53 @@
|
||||||
|
# Kim
|
||||||
|
# System configuration for my desktop
|
||||||
|
|
||||||
|
{ inputs, globals, overlays, ... }:
|
||||||
|
|
||||||
|
with inputs;
|
||||||
|
|
||||||
|
nixpkgs.lib.nixosSystem {
|
||||||
|
system = "x86_64-linux";
|
||||||
|
modules = [
|
||||||
|
globals
|
||||||
|
home-manager.nixosModules.home-manager
|
||||||
|
# ../../modules/common
|
||||||
|
# ../../modules/nixos
|
||||||
|
{
|
||||||
|
# something with overlays, I don't get those yet.
|
||||||
|
|
||||||
|
# Hardware
|
||||||
|
physical = true;
|
||||||
|
networking.hostName = "kim";
|
||||||
|
|
||||||
|
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" ];
|
||||||
|
boot.initrd.kernelModules = [ "amdgpu" ];
|
||||||
|
boot.kernelModules = [ "kvm-amd" ];
|
||||||
|
services.xserver.videoDrivers = [ "amdgpu" ]; # TODO: I use wayland, do I need this?
|
||||||
|
hardware.enableRedistributableFirmware = true;
|
||||||
|
powerManagement.cpuFreqGovernor = "performance";
|
||||||
|
hardware.cpu.amd.updateMicrocode = true;
|
||||||
|
|
||||||
|
fileSystems."/" =
|
||||||
|
{
|
||||||
|
device = "/dev/disk/by-uuid/ba4362a3-3a0b-4227-b460-a5a9302f5966";
|
||||||
|
fsType = "ext4";
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/boot" =
|
||||||
|
{
|
||||||
|
device = "/dev/disk/by-uuid/DB88-8E65";
|
||||||
|
fsType = "vfat";
|
||||||
|
options = [ "fmask=0022" "dmask=0022" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
swapDevices = [ ];
|
||||||
|
|
||||||
|
networking.useDHCP = lib.mkDefault true;
|
||||||
|
|
||||||
|
# TODO: identityFile = "/home/${globals.user}/.ssh/id_ed2519";
|
||||||
|
# TODO: passwordHash = nixpkgs.lib.fileContents ../../password.sha512;
|
||||||
|
|
||||||
|
# Theming?
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue