feat: Nixos-testbed is back
This commit is contained in:
@@ -1,18 +1,15 @@
|
||||
{ config, pkgs, lib, disko, sydnix-cli, ... }:
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./disko-config.nix
|
||||
./hardware.nix
|
||||
./disks.nix
|
||||
];
|
||||
|
||||
sydnix = {
|
||||
filesystemType = "btrfs";
|
||||
|
||||
tailscale.enable = true;
|
||||
dropbox.enable = false;
|
||||
|
||||
users.users = [
|
||||
"crumb"
|
||||
"lain"
|
||||
];
|
||||
|
||||
impermanence = {
|
||||
@@ -27,29 +24,25 @@
|
||||
# just think it's annoying to edit ~/.ssh/known_hosts all the time.
|
||||
"/etc/ssh"
|
||||
];
|
||||
rollback = {
|
||||
enable = true;
|
||||
device = "/dev/sda2";
|
||||
subvolume = "rootfs";
|
||||
};
|
||||
# rollback = {
|
||||
# enable = true;
|
||||
# device = "/dev/sda2";
|
||||
# subvolume = "rootfs";
|
||||
# };
|
||||
};
|
||||
};
|
||||
|
||||
boot = {
|
||||
loader = {
|
||||
boot.loader = {
|
||||
systemd-boot.enable = true;
|
||||
efi.canTouchEfiVariables = false;
|
||||
};
|
||||
};
|
||||
|
||||
# VM-specific. }:3
|
||||
fileSystems."/persist/dots" = {
|
||||
device = "mount-dots";
|
||||
fsType = "virtiofs";
|
||||
mountPoint = "/persist/dots";
|
||||
};
|
||||
|
||||
# networking.hostName = "nixos-testbed";
|
||||
networking.hostId = "238e9b1e"; # head -c 8 /etc/machine-id
|
||||
|
||||
time.timeZone = "America/Denver";
|
||||
@@ -58,31 +51,19 @@
|
||||
|
||||
console = {
|
||||
font = "Lat2-Terminus16";
|
||||
# keyMap = "us";
|
||||
useXkbConfig = true; # use xkb.options in tty.
|
||||
useXkbConfig = true; # Use xkb.options in TTY.
|
||||
};
|
||||
|
||||
services.xserver.enable = true;
|
||||
services.displayManager.sddm = {
|
||||
enable = true;
|
||||
wayland.enable = true;
|
||||
autoNumlock = true;
|
||||
};
|
||||
# services.desktopManager.plasma6.enable = true;
|
||||
|
||||
services.xserver.xkb.layout = "us";
|
||||
services.xserver.xkb.options = "ctrl:swapcaps";
|
||||
|
||||
environment.systemPackages = [
|
||||
pkgs.neovim
|
||||
pkgs.git
|
||||
pkgs.waypipe
|
||||
sydnix-cli.packages.x86_64-linux.default
|
||||
(import ../../scripts/port-tools { inherit pkgs; })
|
||||
|
||||
# Waypipe provides the equivalent of X11 forwarding for Wayland. This is a
|
||||
# VM, so it's very handy.
|
||||
pkgs.waypipe
|
||||
pkgs.cachix
|
||||
];
|
||||
|
||||
services.openssh = {
|
||||
@@ -91,17 +72,8 @@
|
||||
settings.X11Forwarding = true;
|
||||
};
|
||||
|
||||
# TODO: Move to defaults.
|
||||
users.mutableUsers = false;
|
||||
|
||||
# services.xserver.windowManager.qtile = {
|
||||
# enable = true;
|
||||
# extraPackages = python3Packages: with python3Packages; [
|
||||
# qtile-extras
|
||||
# hy
|
||||
# ];
|
||||
# };
|
||||
|
||||
nix = {
|
||||
settings = {
|
||||
trusted-users = [
|
||||
|
||||
@@ -1,6 +1,10 @@
|
||||
# sudo nix --experimental-features "nix-command flakes" run github:nix-community/disko/latest -- --mode disko /persist/dots/hosts/nixos-testbed/disko-config.nix
|
||||
# time sudo nixos-install --flake /persist/dots#nixos-testbed
|
||||
{ lib, ... }:
|
||||
{ lib
|
||||
, devices ? { bootroot = "/dev/vda"; }
|
||||
, ...
|
||||
}:
|
||||
|
||||
{
|
||||
# imports = [ disko.nixosModules.disko ];
|
||||
boot.initrd.supportedFilesystems.btrfs = true;
|
||||
@@ -13,9 +17,9 @@
|
||||
|
||||
disko.devices = {
|
||||
disk = {
|
||||
bootroot = {
|
||||
testbed-bootroot = {
|
||||
type = "disk";
|
||||
device = "/dev/sda";
|
||||
device = devices.bootroot;
|
||||
content = {
|
||||
type = "gpt";
|
||||
partitions = {
|
||||
Reference in New Issue
Block a user