Skip to content

Commit

Permalink
feat: welcome playsatan
Browse files Browse the repository at this point in the history
  • Loading branch information
truxnell committed Jul 5, 2024
1 parent f3c7f1a commit 2658dd3
Show file tree
Hide file tree
Showing 4 changed files with 89 additions and 2 deletions.
2 changes: 1 addition & 1 deletion docs/vm/installing-zfs-impermance.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ zfs create -p -o mountpoint=legacy rpool/safe/persist
mkdir /mnt/persist
mount -t zfs rpool/safe/persist /mnt/persist

Set ` networking.hostid`` in the nixos config to `head -c 8 /etc/machine-id`
Set ` networking.hostId`` in the nixos config to `head -c 8 /etc/machine-id`

nixos-install --impure --flake github:truxnell/nix-config#<MACHINE_ID>

Expand Down
15 changes: 15 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,21 @@
];
};

"playsatan" = mkNixosConfig {
# nuci5 tv streaming

hostname = "playsatan";
system = "x86_64-linux";
hardwareModules = [
./nixos/profiles/hw-generic-x86.nix
];
profileModules = [
./nixos/profiles/role-server.nix
{ home-manager.users.truxnell = ./nixos/home/truxnell/server.nix; }
];
};





Expand Down
72 changes: 72 additions & 0 deletions nixos/hosts/playsatan/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page, on
# https://search.nixos.org/options and in the NixOS manual (`nixos-help`).
{ config
, lib
, pkgs
, ...
}: {
mySystem.purpose = "Media Streaming";
mySystem.system.impermanence.enable = true;
mySystem.system.autoUpgrade.enable=true; # bold move cotton
mySystem.services = {
openssh.enable = true;

};

mySystem.nfs.nas.enable = true;
mySystem.persistentFolder = "/persist";
mySystem.system.motd.networkInterfaces = [ "enp1s0" ];

mySystem.nasFolder = "/mnt/nas";
mySystem.system.resticBackup.local.location = "/mnt/nas/backup/nixos/nixos";


boot = {

initrd.availableKernelModules = [ "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" "sr_mod" "rtsx_pci_sdmmc" ];
initrd.kernelModules = [ ];
kernelModules = [ "kvm-intel" ];
extraModulePackages = [ ];

# for managing/mounting ntfs
supportedFilesystems = [ "ntfs" ];

loader = {
systemd-boot.enable = true;
efi.canTouchEfiVariables = true;
# why not ensure we can memtest workstatons easily?
# TODO check whether this is actually working, cant see it in grub?
grub.memtest86.enable = true;

};
};

networking.hostName = "playsatan"; # Define your hostname.
networking.hostId = "b8cc9645";
networking.useDHCP = lib.mkDefault true;

fileSystems."/" =
{ device = "rpool/local/root";
fsType = "zfs";
};

fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/72A3-FA67";
fsType = "vfat";
};

fileSystems."/nix" =
{ device = "rpool/local/nix";
fsType = "zfs";
};

fileSystems."/persist" =
{ device = "rpool/safe/persist";
fsType = "zfs";
neededForBoot = true; # for impermanence
};

swapDevices = [ ];

}
2 changes: 1 addition & 1 deletion nixos/hosts/shodan/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
zigbee2mqtt.enable = true;
node-red.enable = true;
home-assistant.enable = true;
code-server.enable = true; # Why is this bringing in gtk and wayland?
code-server.enable = true;

radicale.enable = true;
miniflux.enable = true;
Expand Down

0 comments on commit 2658dd3

Please sign in to comment.