This commit is contained in:
Michael Thomas 2024-01-17 11:44:56 -05:00
commit 2b206b1f91
7 changed files with 136 additions and 11 deletions

View File

@ -98,6 +98,24 @@
specialArgs = {inherit inputs;};
};
thinkcentre = nixpkgs.lib.nixosSystem {
system = utils.lib.system.x86_64-linux;
modules = [
self.overlaysModule
home-manager.nixosModules.home-manager
./modules/common.nix
./modules/containers.nix
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.michael = import ./user/environments/nixos/home.nix;
}
./machines/thinkcentre/configuration.nix
];
specialArgs = {inherit inputs;};
};
# WSL environment
work = inputs.nixpkgs.lib.nixosSystem {
system = utils.lib.system.x86_64-linux;

View File

@ -1,11 +1,4 @@
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help).
{
config,
pkgs,
...
}: {
{pkgs, ...}: {
imports = [
# Include the results of the hardware scan.
./hardware-configuration.nix

View File

@ -0,0 +1,58 @@
{pkgs, ...}: {
imports = [
# Include the results of the hardware scan.
./hardware-configuration.nix
];
networking.hostName = "venus"; # Define your hostname.
# Set your time zone.
time.timeZone = "America/New_York";
# Select internationalisation properties.
i18n.defaultLocale = "en_US.UTF-8";
i18n.extraLocaleSettings = {
LC_ADDRESS = "en_US.UTF-8";
LC_IDENTIFICATION = "en_US.UTF-8";
LC_MEASUREMENT = "en_US.UTF-8";
LC_MONETARY = "en_US.UTF-8";
LC_NAME = "en_US.UTF-8";
LC_NUMERIC = "en_US.UTF-8";
LC_PAPER = "en_US.UTF-8";
LC_TELEPHONE = "en_US.UTF-8";
LC_TIME = "en_US.UTF-8";
};
# Configure keymap in X11
services.xserver = {
layout = "us";
xkbVariant = "";
};
swapDevices = [
{
device = "/swapfile";
priority = 0;
size = 16384;
}
];
programs.zsh.enable = true;
# Define a user account. Don't forget to set a password with passwd.
users.users.michael = {
isNormalUser = true;
description = "Michael Thomas";
extraGroups = ["wheel" "docker" "podman" "adbusers" "dialout"];
shell = pkgs.zsh;
};
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "23.11"; # Did you read the comment?
}

View File

@ -0,0 +1,37 @@
# 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" "nvme" "usbhid" "usb_storage" "sd_mod" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ ];
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/2b1793d6-feff-48df-9180-03e8c2bef7bf";
fsType = "ext4";
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/2082-08EF";
fsType = "vfat";
};
swapDevices = [ ];
# 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.enp0s31f6.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}

View File

@ -4,4 +4,5 @@
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = false;
boot.plymouth.enable = true;
boot.kernelParams = ["quiet"];
}

View File

@ -1,5 +1,20 @@
{
# Enable sound.
sound.enable = true;
hardware.pulseaudio.enable = true;
hardware.pulseaudio.enable = false;
security.rtkit.enable = true;
# Enable pipewire
services.pipewire = {
enable = true;
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
# If you want to use JACK applications, uncomment this
#jack.enable = true;
# use the example session manager (no others are packaged yet so this is enabled by default,
# no need to redefine it in your config for now)
#media-session.enable = true;
};
}

View File

@ -1,9 +1,12 @@
{pkgs, ...}: {
# Use pkgs.gitAndTools.gitFull in order to get libsecret support
programs.git = {
package = pkgs.gitAndTools.gitFull;
extraConfig = {
credential.helper = "libsecret";
credential.helper = "oauth";
};
};
home.packages = with pkgs; [
git-credential-oauth
];
}