Compare commits
4 commits
f5e72e217f
...
ae01142320
Author | SHA1 | Date | |
---|---|---|---|
ae01142320 | |||
18a8556187 | |||
0cc727adaa | |||
c8f19a86ee |
8 changed files with 239 additions and 1 deletions
21
devshells/python.nix
Normal file
21
devshells/python.nix
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
{
|
||||||
|
withSystem,
|
||||||
|
inputs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
perSystem = {
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
devShells.python = pkgs.mkShell {
|
||||||
|
buildInputs = with pkgs; [
|
||||||
|
(python3.withPackages (ps:
|
||||||
|
with ps; [
|
||||||
|
pip
|
||||||
|
virtualenv
|
||||||
|
]))
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
18
devshells/typst.nix
Normal file
18
devshells/typst.nix
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
{
|
||||||
|
withSystem,
|
||||||
|
inputs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
perSystem = {
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
lib,
|
||||||
|
inputs',
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
devShells.typst = pkgs.mkShell {
|
||||||
|
buildInputs = with inputs'.nixpkgs-unstable.legacyPackages; [
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -32,13 +32,17 @@
|
||||||
./nixos/machines/installer/configuration.nix
|
./nixos/machines/installer/configuration.nix
|
||||||
./nixos/machines/crash/machine.nix
|
./nixos/machines/crash/machine.nix
|
||||||
./nixos/machines/tides/machine.nix
|
./nixos/machines/tides/machine.nix
|
||||||
|
./nixos/machines/driftwood/machine.nix
|
||||||
./home-manager/machines/wsl/home.nix
|
./home-manager/machines/wsl/home.nix
|
||||||
./home-manager/machines/crash/home.nix
|
./home-manager/machines/crash/home.nix
|
||||||
./home-manager/machines/tides/home.nix
|
./home-manager/machines/tides/home.nix
|
||||||
|
./home-manager/machines/driftwood/home.nix
|
||||||
./devshells/rust.nix
|
./devshells/rust.nix
|
||||||
./devshells/idris2.nix
|
./devshells/idris2.nix
|
||||||
./devshells/raku.nix
|
./devshells/raku.nix
|
||||||
./devshells/markdown.nix
|
./devshells/markdown.nix
|
||||||
|
./devshells/typst.nix
|
||||||
|
./devshells/python.nix
|
||||||
];
|
];
|
||||||
config = {
|
config = {
|
||||||
systems = [
|
systems = [
|
||||||
|
|
|
@ -77,7 +77,12 @@
|
||||||
newsflash
|
newsflash
|
||||||
liferea
|
liferea
|
||||||
# Crypto
|
# Crypto
|
||||||
exodus
|
# exodus
|
||||||
|
# 3d printing
|
||||||
|
# bambu-studio
|
||||||
|
orca-slicer
|
||||||
|
openscad-unstable
|
||||||
|
vscode
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
51
home-manager/machines/driftwood/home.nix
Normal file
51
home-manager/machines/driftwood/home.nix
Normal file
|
@ -0,0 +1,51 @@
|
||||||
|
{
|
||||||
|
withSystem,
|
||||||
|
inputs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
# perSystem = { ... }: { config.packages.hello = ...; };
|
||||||
|
|
||||||
|
flake.homeConfigurations.tides = withSystem "x86_64-linux" (
|
||||||
|
ctx @ {
|
||||||
|
config,
|
||||||
|
inputs',
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
inputs.home-manager.lib.homeManagerConfiguration {
|
||||||
|
pkgs = inputs.nixpkgs.legacyPackages.${"x86_64-linux"};
|
||||||
|
extraSpecialArgs = {
|
||||||
|
inherit inputs inputs';
|
||||||
|
packages = config.packages;
|
||||||
|
};
|
||||||
|
modules = [
|
||||||
|
(
|
||||||
|
{
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
imports = [
|
||||||
|
../../modules/programs/shell.nix
|
||||||
|
../../modules/programs/neovim.nix
|
||||||
|
(import ../../modules/programs/git.nix {})
|
||||||
|
../../modules/programs/core.nix
|
||||||
|
../../modules/programs/ssh.nix
|
||||||
|
];
|
||||||
|
home.username = "nathan";
|
||||||
|
home.homeDirectory = "/home/nathan/";
|
||||||
|
programs.command-not-found.enable = true;
|
||||||
|
home.stateVersion = "24.11";
|
||||||
|
programs.home-manager.enable = true;
|
||||||
|
|
||||||
|
# Allow unfree packages
|
||||||
|
nixpkgs.config.allowUnfree = true;
|
||||||
|
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
];
|
||||||
|
}
|
||||||
|
)
|
||||||
|
];
|
||||||
|
}
|
||||||
|
);
|
||||||
|
}
|
20
nixos/machines/driftwood/configuration.nix
Normal file
20
nixos/machines/driftwood/configuration.nix
Normal file
|
@ -0,0 +1,20 @@
|
||||||
|
# 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, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
# Use the systemd-boot EFI boot loader.
|
||||||
|
boot.loader.systemd-boot.enable = true;
|
||||||
|
boot.loader.efi.canTouchEfiVariables = true;
|
||||||
|
|
||||||
|
networking.hostName = "driftwood";
|
||||||
|
|
||||||
|
time.timeZone = "America/Louisville";
|
||||||
|
i18n.defaultLocale = "en_US.UTF-8";
|
||||||
|
|
||||||
|
system.stateVersion = "24.11"; # Did you read the comment?
|
||||||
|
|
||||||
|
}
|
||||||
|
|
67
nixos/machines/driftwood/hardware.nix
Normal file
67
nixos/machines/driftwood/hardware.nix
Normal file
|
@ -0,0 +1,67 @@
|
||||||
|
# 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" "usbhid" "sd_mod" ];
|
||||||
|
boot.initrd.kernelModules = [ ];
|
||||||
|
boot.kernelModules = [ "kvm-amd" ];
|
||||||
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
|
fileSystems."/" =
|
||||||
|
{ device = "/dev/disk/by-uuid/e9e1adfb-feb9-4456-80a0-d8d306b36145";
|
||||||
|
fsType = "btrfs";
|
||||||
|
options = [ "subvol=root" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/nix" =
|
||||||
|
{ device = "/dev/disk/by-uuid/e9e1adfb-feb9-4456-80a0-d8d306b36145";
|
||||||
|
fsType = "btrfs";
|
||||||
|
options = [ "subvol=nix" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/var" =
|
||||||
|
{ device = "/dev/disk/by-uuid/e9e1adfb-feb9-4456-80a0-d8d306b36145";
|
||||||
|
fsType = "btrfs";
|
||||||
|
options = [ "subvol=var" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/home" =
|
||||||
|
{ device = "/dev/disk/by-uuid/e9e1adfb-feb9-4456-80a0-d8d306b36145";
|
||||||
|
fsType = "btrfs";
|
||||||
|
options = [ "subvol=home" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/etc" =
|
||||||
|
{ device = "/dev/disk/by-uuid/e9e1adfb-feb9-4456-80a0-d8d306b36145";
|
||||||
|
fsType = "btrfs";
|
||||||
|
options = [ "subvol=etc" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/boot" =
|
||||||
|
{ device = "/dev/disk/by-uuid/DE13-B03B";
|
||||||
|
fsType = "vfat";
|
||||||
|
options = [ "fmask=0022" "dmask=0022" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
swapDevices =
|
||||||
|
[ { device = "/dev/disk/by-uuid/fe4935bf-ae69-4529-87cd-1a913c346876"; }
|
||||||
|
];
|
||||||
|
|
||||||
|
# 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.enp5s0f0.useDHCP = lib.mkDefault true;
|
||||||
|
# networking.interfaces.enp5s0f1.useDHCP = lib.mkDefault true;
|
||||||
|
# networking.interfaces.enp7s0f3u2u2c2.useDHCP = lib.mkDefault true;
|
||||||
|
|
||||||
|
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||||
|
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||||
|
}
|
52
nixos/machines/driftwood/machine.nix
Normal file
52
nixos/machines/driftwood/machine.nix
Normal file
|
@ -0,0 +1,52 @@
|
||||||
|
{
|
||||||
|
withSystem,
|
||||||
|
inputs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
# perSystem = { ... }: { config.packages.hello = ...; };
|
||||||
|
|
||||||
|
flake.nixosConfigurations.driftwood = withSystem "aarch64-linux" (
|
||||||
|
ctx @ {
|
||||||
|
config,
|
||||||
|
inputs',
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
inputs.nixpkgs.lib.nixosSystem {
|
||||||
|
# Expose `packages`, `inputs` and `inputs'` as module arguments.
|
||||||
|
# Use specialArgs permits use in `imports`.
|
||||||
|
# Note: if you publish modules for reuse, do not rely on specialArgs, but
|
||||||
|
# on the flake scope instead. See also https://flake.parts/define-module-in-separate-file.html
|
||||||
|
specialArgs = {
|
||||||
|
packages = config.packages;
|
||||||
|
inherit inputs inputs';
|
||||||
|
};
|
||||||
|
modules = [
|
||||||
|
(
|
||||||
|
{
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
imports = [
|
||||||
|
# Our modules
|
||||||
|
(import ../../modules/base.nix {inherit inputs;})
|
||||||
|
(import ./configuration.nix)
|
||||||
|
(import ./hardware.nix)
|
||||||
|
(import ../../modules/user.nix {
|
||||||
|
inherit inputs;
|
||||||
|
mutableUsers = false;
|
||||||
|
})
|
||||||
|
(import ../../modules/ssh.nix)
|
||||||
|
];
|
||||||
|
|
||||||
|
nix.settings.experimental-features = [
|
||||||
|
"nix-command"
|
||||||
|
"flakes"
|
||||||
|
];
|
||||||
|
}
|
||||||
|
)
|
||||||
|
];
|
||||||
|
}
|
||||||
|
);
|
||||||
|
}
|
Loading…
Add table
Reference in a new issue