feat: drop bento, add yuba (WSL)
This commit is contained in:
parent
11011387de
commit
8618fa8858
11 changed files with 62 additions and 109 deletions
27
flake.lock
27
flake.lock
|
@ -393,7 +393,8 @@
|
||||||
"nixpkgs": "nixpkgs_2",
|
"nixpkgs": "nixpkgs_2",
|
||||||
"nur": "nur",
|
"nur": "nur",
|
||||||
"pre-commit-hooks": "pre-commit-hooks",
|
"pre-commit-hooks": "pre-commit-hooks",
|
||||||
"swayfx": "swayfx"
|
"swayfx": "swayfx",
|
||||||
|
"wsl": "wsl"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"rust-overlay": {
|
"rust-overlay": {
|
||||||
|
@ -486,6 +487,30 @@
|
||||||
"repo": "default",
|
"repo": "default",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"wsl": {
|
||||||
|
"inputs": {
|
||||||
|
"flake-compat": [],
|
||||||
|
"flake-utils": [
|
||||||
|
"flake-utils"
|
||||||
|
],
|
||||||
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1707476384,
|
||||||
|
"narHash": "sha256-9YortZTCO9r7wFHX92t+npUDmD5VcKrkVmwaPCvEiXI=",
|
||||||
|
"owner": "nix-community",
|
||||||
|
"repo": "nixos-wsl",
|
||||||
|
"rev": "76ca59d8d4423b27c0238bc31401692ebc571365",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nix-community",
|
||||||
|
"repo": "nixos-wsl",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"root": "root",
|
"root": "root",
|
||||||
|
|
15
flake.nix
15
flake.nix
|
@ -16,8 +16,8 @@
|
||||||
host = "sashimi";
|
host = "sashimi";
|
||||||
system = "aarch64-darwin";
|
system = "aarch64-darwin";
|
||||||
username = "winston";
|
username = "winston";
|
||||||
extraModules = [inputs.nekowinston-nur.darwinModules.default];
|
|
||||||
isGraphical = true;
|
isGraphical = true;
|
||||||
|
extraModules = [inputs.nekowinston-nur.darwinModules.default];
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
host = "futomaki";
|
host = "futomaki";
|
||||||
|
@ -26,10 +26,11 @@
|
||||||
isGraphical = true;
|
isGraphical = true;
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
host = "bento";
|
host = "yuba";
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
username = "w";
|
username = "winston";
|
||||||
isGraphical = true;
|
isGraphical = false;
|
||||||
|
extraModules = [inputs.wsl.nixosModules.default];
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
imports = [inputs.pre-commit-hooks.flakeModule];
|
imports = [inputs.pre-commit-hooks.flakeModule];
|
||||||
|
@ -112,6 +113,12 @@
|
||||||
url = "github:nix-community/home-manager";
|
url = "github:nix-community/home-manager";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
wsl = {
|
||||||
|
url = "github:nix-community/nixos-wsl";
|
||||||
|
inputs.flake-compat.follows = "";
|
||||||
|
inputs.flake-utils.follows = "flake-utils";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
|
||||||
nur.url = "github:nix-community/nur";
|
nur.url = "github:nix-community/nur";
|
||||||
caarlos0-nur = {
|
caarlos0-nur = {
|
||||||
|
|
|
@ -53,6 +53,7 @@
|
||||||
];
|
];
|
||||||
|
|
||||||
extraConfig = {
|
extraConfig = {
|
||||||
|
core.fsmonitor = "rs-git-fsmonitor";
|
||||||
credential.helper = "gopass";
|
credential.helper = "gopass";
|
||||||
init.defaultBranch = "main";
|
init.defaultBranch = "main";
|
||||||
push.default = "current";
|
push.default = "current";
|
||||||
|
|
|
@ -1,32 +0,0 @@
|
||||||
{
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
imports = [./hardware.nix];
|
|
||||||
|
|
||||||
boot = {
|
|
||||||
kernelPackages = pkgs.linuxPackages_latest;
|
|
||||||
kernelParams = ["quiet" "splash"];
|
|
||||||
};
|
|
||||||
|
|
||||||
hardware = {
|
|
||||||
bluetooth.enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
networking = {
|
|
||||||
hostName = "bento";
|
|
||||||
networkmanager.enable = true;
|
|
||||||
firewall.enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
time.timeZone = "Europe/Vienna";
|
|
||||||
i18n.defaultLocale = "en_US.UTF-8";
|
|
||||||
|
|
||||||
services = {
|
|
||||||
openssh.enable = true;
|
|
||||||
pcscd.enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
virtualisation.podman.enable = true;
|
|
||||||
}
|
|
|
@ -1,66 +0,0 @@
|
||||||
# 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,
|
|
||||||
modulesPath,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
imports = [
|
|
||||||
(modulesPath + "/installer/scan/not-detected.nix")
|
|
||||||
];
|
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = ["xhci_pci" "ahci" "nvme" "usb_storage" "sd_mod" "sr_mod"];
|
|
||||||
boot.initrd.kernelModules = ["dm-snapshot"];
|
|
||||||
boot.kernelModules = ["kvm-intel"];
|
|
||||||
boot.extraModulePackages = [];
|
|
||||||
|
|
||||||
boot.loader.systemd-boot.consoleMode = "0";
|
|
||||||
|
|
||||||
boot.initrd.luks.devices = {
|
|
||||||
luksroot = {
|
|
||||||
device = "/dev/disk/by-uuid/1af1c538-b38a-43f3-9ad2-9da8a946db7f";
|
|
||||||
preLVM = true;
|
|
||||||
allowDiscards = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/" = {
|
|
||||||
device = "/dev/disk/by-uuid/83c767e9-9efd-4f85-990d-e5cfb9200167";
|
|
||||||
fsType = "btrfs";
|
|
||||||
options = ["subvol=root" "compress=zstd"];
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/home" = {
|
|
||||||
device = "/dev/disk/by-uuid/83c767e9-9efd-4f85-990d-e5cfb9200167";
|
|
||||||
fsType = "btrfs";
|
|
||||||
options = ["subvol=home" "compress=zstd"];
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/nix" = {
|
|
||||||
device = "/dev/disk/by-uuid/83c767e9-9efd-4f85-990d-e5cfb9200167";
|
|
||||||
fsType = "btrfs";
|
|
||||||
options = ["subvol=nix" "compress=zstd" "noatime"];
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/boot" = {
|
|
||||||
device = "/dev/disk/by-uuid/9382-B533";
|
|
||||||
fsType = "vfat";
|
|
||||||
};
|
|
||||||
|
|
||||||
swapDevices = [
|
|
||||||
{device = "/dev/disk/by-uuid/fd70f74e-f2a8-4117-a2c0-355736b162e0";}
|
|
||||||
];
|
|
||||||
|
|
||||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
|
||||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
|
||||||
# still possible to use this option, but it's recommended to use it in conjunction
|
|
||||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
|
||||||
networking.useDHCP = lib.mkDefault true;
|
|
||||||
# networking.interfaces.eno1.useDHCP = lib.mkDefault true;
|
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
|
||||||
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
|
||||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
|
||||||
}
|
|
|
@ -39,8 +39,6 @@
|
||||||
programs.zsh.enable = true;
|
programs.zsh.enable = true;
|
||||||
environment.systemPackages = [pkgs.xdg-utils];
|
environment.systemPackages = [pkgs.xdg-utils];
|
||||||
|
|
||||||
system.stateVersion = "22.11";
|
|
||||||
|
|
||||||
# enable yubikey u2f support
|
# enable yubikey u2f support
|
||||||
security.pam.u2f = {
|
security.pam.u2f = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
12
machines/common/wsl/default.nix
Normal file
12
machines/common/wsl/default.nix
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
{
|
||||||
|
lib,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
services.kanata.enable = lib.mkForce false;
|
||||||
|
|
||||||
|
system = {
|
||||||
|
build.installBootLoader = lib.mkForce "${pkgs.coreutils}/bin/true";
|
||||||
|
stateVersion = "23.11";
|
||||||
|
};
|
||||||
|
}
|
|
@ -6,7 +6,6 @@
|
||||||
imports = [./hardware.nix];
|
imports = [./hardware.nix];
|
||||||
|
|
||||||
networking = {
|
networking = {
|
||||||
hostName = "futomaki";
|
|
||||||
networkmanager.enable = true;
|
networkmanager.enable = true;
|
||||||
firewall.enable = true;
|
firewall.enable = true;
|
||||||
};
|
};
|
||||||
|
@ -60,4 +59,6 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
system.stateVersion = "22.11";
|
||||||
}
|
}
|
||||||
|
|
|
@ -68,6 +68,9 @@
|
||||||
description = "Whether the system is a graphical target";
|
description = "Whether the system is a graphical target";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
config = {
|
||||||
|
networking.hostName = host;
|
||||||
|
};
|
||||||
}
|
}
|
||||||
./common/shared
|
./common/shared
|
||||||
./common/${hostPlatform}
|
./common/${hostPlatform}
|
||||||
|
|
|
@ -1,9 +1,6 @@
|
||||||
{
|
{
|
||||||
imports = [./brew.nix];
|
imports = [./brew.nix];
|
||||||
|
|
||||||
networking.computerName = "sashimi";
|
|
||||||
networking.hostName = "sashimi";
|
|
||||||
|
|
||||||
nix.settings.extra-platforms = [
|
nix.settings.extra-platforms = [
|
||||||
"aarch64-darwin"
|
"aarch64-darwin"
|
||||||
"x86_64-darwin"
|
"x86_64-darwin"
|
||||||
|
|
7
machines/yuba/default.nix
Normal file
7
machines/yuba/default.nix
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
{
|
||||||
|
imports = [../common/wsl];
|
||||||
|
wsl = {
|
||||||
|
defaultUser = "winston";
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
}
|
Loading…
Reference in a new issue