~moody/sakuya

0ebbab8892db5e4856d41034c978cdb734856b52 — Jacob Moody 2 months ago 35854e0 nitori
add nitori
6 files changed, 185 insertions(+), 7 deletions(-)

M flake.lock
M flake.nix
M home.nix
A nitori-hardware.nix
A nitori.nix
M sakuya.nix
M flake.lock => flake.lock +50 -6
@@ 28,11 28,11 @@
        ]
      },
      "locked": {
        "lastModified": 1701728041,
        "narHash": "sha256-x0pyrI1vC8evVDxCxyO6olOyr4wlFg9+VS3C3p4xFYQ=",
        "lastModified": 1705708511,
        "narHash": "sha256-3f4BkRY70Fj7yvuo87c4QQPAjnt571g2wJ50jY7hnYc=",
        "owner": "nix-community",
        "repo": "home-manager",
        "rev": "ac7216918cd65f3824ba7817dea8f22e61221eaf",
        "rev": "ce4b88c465d928f4f8b75d0920f1788d5b65ca94",
        "type": "github"
      },
      "original": {


@@ 41,13 41,56 @@
        "type": "github"
      }
    },
    "jovian": {
      "inputs": {
        "nix-github-actions": "nix-github-actions",
        "nixpkgs": [
          "nixpkgs"
        ]
      },
      "locked": {
        "lastModified": 1705667791,
        "narHash": "sha256-J0JYfA6eFdHluLnROVDkrqbYacWcJXYKXeJAFayDiAE=",
        "owner": "jovian-Experiments",
        "repo": "Jovian-NixOS",
        "rev": "330b7a78fcba967f2273ae71fb3c4bfb03b5dd21",
        "type": "github"
      },
      "original": {
        "owner": "jovian-Experiments",
        "repo": "Jovian-NixOS",
        "type": "github"
      }
    },
    "nix-github-actions": {
      "inputs": {
        "nixpkgs": [
          "jovian",
          "nixpkgs"
        ]
      },
      "locked": {
        "lastModified": 1690328911,
        "narHash": "sha256-fxtExYk+aGf2YbjeWQ8JY9/n9dwuEt+ma1eUFzF8Jeo=",
        "owner": "zhaofengli",
        "repo": "nix-github-actions",
        "rev": "96df4a39c52f53cb7098b923224d8ce941b64747",
        "type": "github"
      },
      "original": {
        "owner": "zhaofengli",
        "ref": "matrix-name",
        "repo": "nix-github-actions",
        "type": "github"
      }
    },
    "nixpkgs": {
      "locked": {
        "lastModified": 1701693815,
        "narHash": "sha256-7BkrXykVWfkn6+c1EhFA3ko4MLi3gVG0p9G96PNnKTM=",
        "lastModified": 1705697961,
        "narHash": "sha256-XepT3WS516evSFYkme3GrcI3+7uwXHqtHbip+t24J7E=",
        "owner": "NixOS",
        "repo": "nixpkgs",
        "rev": "09ec6a0881e1a36c29d67497693a67a16f4da573",
        "rev": "e5d1c87f5813afde2dda384ac807c57a105721cc",
        "type": "github"
      },
      "original": {


@@ 59,6 102,7 @@
      "inputs": {
        "gameover": "gameover",
        "home-manager": "home-manager",
        "jovian": "jovian",
        "nixpkgs": "nixpkgs",
        "vacme-vim": "vacme-vim"
      }

M flake.nix => flake.nix +16 -1
@@ 7,6 7,9 @@
    home-manager.url = "github:nix-community/home-manager";
    home-manager.inputs.nixpkgs.follows = "nixpkgs";

    jovian.url = "github:jovian-Experiments/Jovian-NixOS";
    jovian.inputs.nixpkgs.follows = "nixpkgs";

    gameover.url = "github:majiru/gameover";
    gameover.inputs.nixpkgs.follows = "nixpkgs";



@@ 16,7 19,7 @@
    };
  };

  outputs = { self, nixpkgs, ... }@inputs: {
  outputs = { self, nixpkgs, jovian, ... }@inputs: {
    nixosConfigurations = {
      "sakuya" = nixpkgs.lib.nixosSystem {
        system = "x86_64-linux";


@@ 40,6 43,18 @@
          ./home.nix
        ];
      };
      "nitori" = nixpkgs.lib.nixosSystem {
        system = "x86_64-linux";
        specialArgs = { inherit inputs; };
        modules = [
          ./nitori-hardware.nix
          ./prefs.nix
          ./nix.nix
          jovian.outputs.nixosModules.jovian
          ./nitori.nix
          ./home.nix
        ];
      };
    };
  };
}

M home.nix => home.nix +1 -0
@@ 198,6 198,7 @@
            };
          };
          "marisa"."*".bg = "#b2b2b2 solid_color";
          "nixos"."*".bg = "#b2b2b2 solid_color";
        }."${config.networking.hostName}";
      };
    };

A nitori-hardware.nix => nitori-hardware.nix +26 -0
@@ 0,0 1,26 @@
# Do not modify this file!  It was generated by ‘nixos-generate-config’
# and may be overwritten by future invocations.  Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, ... }:

{
  boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "usbhid" "usb_storage" "sd_mod" "sdhci_pci" ];
  boot.initrd.kernelModules = [ ];
  boot.kernelModules = [ "kvm-amd" ];
  boot.extraModulePackages = [ ];

  fileSystems."/" =
    {
      device = "/dev/disk/by-uuid/76f20775-aee9-4ac4-aa62-d5b6dec3b62b";
      fsType = "ext4";
    };

  fileSystems."/boot" =
    {
      device = "/dev/disk/by-uuid/3C03-014D";
      fsType = "vfat";
    };

  nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
  hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}

A nitori.nix => nitori.nix +85 -0
@@ 0,0 1,85 @@
{ config, inputs, pkgs, ... }: {
  boot.kernelPackages = inputs.jovian.outputs.legacyPackages.x86_64-linux.linuxPackages_jovian;
  boot.loader.systemd-boot.enable = true;
  boot.loader.efi.canTouchEfiVariables = true;
  boot.kernel.sysctl = {
    "net.ipv4.tcp_congestion_control" = "reno";
  };

  nixpkgs.overlays = [
    (final: prev: {
      makeModulesClosure = x:
        prev.makeModulesClosure (x // { allowMissing = true; });
    })
  ];
  nixpkgs.config.allowUnfree = true;
  environment.systemPackages = with pkgs; [
    curl
    wayland
    grim
    slurp
    wl-clipboard
    mako
    xdg-utils
    bemenu
    wdisplays
    wget
    firefox
    sway
    telegram-desktop
    pavucontrol
    passage
    gnumake
    gcc
    git
    thunderbird
    gnome3.adwaita-icon-theme
    nawk
    xfce.thunar
    transmission-gtk
    mpv
    jq
    htop
    wlclock
    rc-9front
    drawterm-wayland
    tlsclient
    libnotify
    go
    gopls
    nil
    nixpkgs-fmt
    imv
    ffmpeg
    man-pages
    man-pages-posix
    games.pokecrystal
    games.pokered
    games.shipwright
    games.pokeemerald
    games.zelda3
    games.pokefirered
    games.pokeyellow
    games.pokegold
    pc
    ed
    file
    unzrip
    dolphin-emu
    citra-nightly
  ];

  jovian.devices.steamdeck.enable = true;
  jovian.steam.autoStart = true;
  jovian.steam.desktopSession = "plasmawayland";

  networking.useDHCP = true;
  networking.hostName = "nitori";
  users.users.moody = {
    isNormalUser = true;
    extraGroups = [ "wheel" "video" ];
  };

  services.udev.packages = [ pkgs.dolphin-emu ];
  system.stateVersion = "24.05";
}

M sakuya.nix => sakuya.nix +7 -0
@@ 53,6 53,13 @@
    "${config.systemd.package}/lib/systemd/systemd-networkd-wait-online --any"
  ];

  services.resolved = {
    enable = true;
    extraConfig = ''
      DNSOverTLS=opportunistic
    '';
  };

  security.pam.dp9ik = {
    enable = true;
    authserver = "flan";