forked from Zynh0722/permafrost
permafrost: incarnate
This commit is contained in:
parent
56de2004f1
commit
e0e1d23581
5 changed files with 117 additions and 9 deletions
28
flake.nix
28
flake.nix
|
@ -15,22 +15,42 @@
|
|||
specialArgs = { inherit inputs self; };
|
||||
|
||||
modules = [
|
||||
./configuration.nix
|
||||
./hardware-configuration.nix
|
||||
./modules
|
||||
./hosts/virtmsi/configuration.nix
|
||||
./hosts/virtmsi/hardware-configuration.nix
|
||||
];
|
||||
};
|
||||
permafrost = nixpkgs.lib.nixosSystem {
|
||||
specialArgs = { inherit inputs self; };
|
||||
|
||||
modules = [
|
||||
./modules
|
||||
./hosts/permafrost/configuration.nix
|
||||
./hosts/permafrost/hardware-configuration.nix
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
deploy.nodes.virtmsi = {
|
||||
deploy = {
|
||||
sshUser = "ravenshade";
|
||||
user = "root";
|
||||
hostname = "virtmsi";
|
||||
sshOpts = [ "-A" ];
|
||||
nodes = {
|
||||
virtmsi = {
|
||||
hostname = "virtmsi";
|
||||
profiles.system.path = deploy-rs.lib.x86_64-linux.activate.nixos self.nixosConfigurations.virtmsi;
|
||||
fastConnection = true;
|
||||
interactiveSudo = true;
|
||||
};
|
||||
|
||||
permafrost = {
|
||||
hostname = "permafrost";
|
||||
profiles.system.path = deploy-rs.lib.x86_64-linux.activate.nixos self.nixosConfigurations.permafrost;
|
||||
interactiveSudo = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
checks = builtins.mapAttrs (system: deployLib: deployLib.deployChecks self.deploy) deploy-rs.lib;
|
||||
};
|
||||
}
|
||||
|
|
42
hosts/permafrost/configuration.nix
Normal file
42
hosts/permafrost/configuration.nix
Normal file
|
@ -0,0 +1,42 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
permafrost.nyazoom.enable = true;
|
||||
|
||||
networking.hostName = "permafrost"; # Define your hostname.
|
||||
|
||||
# Allowing ssh auth
|
||||
security.pam.sshAgentAuth.enable = true;
|
||||
|
||||
# Allow unfree packages
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
nix.settings = {
|
||||
auto-optimise-store = true;
|
||||
experimental-features = [ "nix-command" "flakes" ];
|
||||
|
||||
trusted-users = [
|
||||
"ravenshade"
|
||||
];
|
||||
};
|
||||
|
||||
# Enable networking
|
||||
networking.networkmanager.enable = true;
|
||||
|
||||
# Define a user account. Don't forget to set a password with ‘passwd’.
|
||||
users.users.ravenshade = {
|
||||
isNormalUser = true;
|
||||
description = "Zynh Ludwig";
|
||||
extraGroups = [ "networkmanager" "wheel" ];
|
||||
};
|
||||
|
||||
# List packages installed in system profile. To search, run:
|
||||
# $ nix search wget
|
||||
environment.systemPackages = with pkgs; [
|
||||
neovim
|
||||
git
|
||||
curl
|
||||
];
|
||||
|
||||
system.stateVersion = "24.05";
|
||||
|
||||
}
|
48
hosts/permafrost/hardware-configuration.nix
Normal file
48
hosts/permafrost/hardware-configuration.nix
Normal file
|
@ -0,0 +1,48 @@
|
|||
# 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, pkgs, modulesPath, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "usb_storage" "usbhid" "sd_mod" "sr_mod" "rtsx_pci_sdmmc" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" =
|
||||
{
|
||||
device = "/dev/disk/by-uuid/11b049bc-378b-44e6-9d2e-ce5fc897f15a";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
fileSystems."/boot" =
|
||||
{
|
||||
device = "/dev/disk/by-uuid/A4DA-34BD";
|
||||
fsType = "vfat";
|
||||
};
|
||||
|
||||
swapDevices = [ ];
|
||||
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
||||
boot.loader.grub = {
|
||||
enable = true;
|
||||
efiSupport = true;
|
||||
device = "nodev";
|
||||
};
|
||||
|
||||
# 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.enp3s0.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wlp2s0.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
|
@ -1,8 +1,6 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [ ./modules ];
|
||||
|
||||
# Bootloader.
|
||||
boot.loader.grub.enable = true;
|
||||
boot.loader.grub.device = "/dev/vda";
|
Loading…
Reference in a new issue