first commit
This commit is contained in:
parent
7c106c37c7
commit
747524493d
7 changed files with 9 additions and 263 deletions
39
README.md
39
README.md
|
@ -1,38 +1,5 @@
|
||||||
# My NixOS Flake Config
|
# My NixOS Flake Config
|
||||||
My NixOS repo with that has the configs for 2 of my NixOS machines.
|
My NixOS repo for a single machine.
|
||||||
|
|
||||||
## NOTE: Archived.
|
- Flakes
|
||||||
I don't use this anymore. It got too complicated with multiple machines.
|
- Homemanager
|
||||||
|
|
||||||
# Structure of NixOS Config
|
|
||||||
|
|
||||||
```.
|
|
||||||
├── flake.lock
|
|
||||||
├── flake.nix
|
|
||||||
├── flatpak-install.sh
|
|
||||||
├── home.nix
|
|
||||||
├── hosts
|
|
||||||
│ ├── aspirenix
|
|
||||||
│ │ ├── configuration.nix
|
|
||||||
│ │ └── hardware-configuration.nix
|
|
||||||
│ ├── bluenix
|
|
||||||
│ │ ├── configuration.nix
|
|
||||||
│ │ └── hardware-configuration.nix
|
|
||||||
│ └── greynix
|
|
||||||
│ ├── configuration.nix
|
|
||||||
│ └── hardware-configuration.nix
|
|
||||||
├── nixosModules
|
|
||||||
│ ├── base.nix
|
|
||||||
│ ├── docker.nix
|
|
||||||
│ ├── fonts.nix
|
|
||||||
│ ├── gnome.nix
|
|
||||||
│ ├── module-docker.nix
|
|
||||||
│ ├── module-modules.nix
|
|
||||||
│ └── systemd.nix
|
|
||||||
├── nix-upgrade.sh
|
|
||||||
├── pull.sh
|
|
||||||
├── README.md
|
|
||||||
├── rebuild.sh
|
|
||||||
├── temp-non-declarative-stuff.txt
|
|
||||||
└── update.sh
|
|
||||||
```
|
|
||||||
|
|
52
flake.nix
52
flake.nix
|
@ -21,54 +21,14 @@
|
||||||
{
|
{
|
||||||
home-manager.useGlobalPkgs = true;
|
home-manager.useGlobalPkgs = true;
|
||||||
home-manager.useUserPackages = true;
|
home-manager.useUserPackages = true;
|
||||||
home-manager.users.elias = import ./home.nix;
|
home-manager.users.elias = import .nixosModules/home.nix;
|
||||||
|
|
||||||
# Optionally, use home-manager.extraSpecialArgs to pass
|
# Optionally, use home-manager.extraSpecialArgs to pass
|
||||||
# arguments to home.nix
|
# arguments to home.nix
|
||||||
} #close home-manager
|
}
|
||||||
]; #close modules
|
];
|
||||||
}; #close greynix
|
};
|
||||||
|
|
||||||
# bluenix - Blue Acer machine
|
};
|
||||||
bluenix = nixpkgs.lib.nixosSystem {
|
};
|
||||||
system = "x86_64-linux";
|
|
||||||
modules = [
|
|
||||||
./nixosModules/base.nix
|
|
||||||
./hosts/bluenix/configuration.nix
|
|
||||||
./nixosModules/docker.nix
|
|
||||||
|
|
||||||
home-manager.nixosModules.home-manager
|
|
||||||
{
|
|
||||||
home-manager.useGlobalPkgs = true;
|
|
||||||
home-manager.useUserPackages = true;
|
|
||||||
home-manager.users.elias = import ./home.nix;
|
|
||||||
|
|
||||||
# Optionally, use home-manager.extraSpecialArgs to pass
|
|
||||||
# arguments to home.nix
|
|
||||||
} #close homemanager
|
|
||||||
]; #close modules
|
|
||||||
}; # close bluenix
|
|
||||||
|
|
||||||
# aspirenix - Grey Acer Aspire machine
|
|
||||||
# low spec machine - need to figure out how to change this config a bit
|
|
||||||
aspirenix = nixpkgs.lib.nixosSystem {
|
|
||||||
system = "x86_64-linux";
|
|
||||||
modules = [
|
|
||||||
./nixosModules/base.nix
|
|
||||||
./hosts/aspirenix/configuration.nix
|
|
||||||
|
|
||||||
home-manager.nixosModules.home-manager
|
|
||||||
{
|
|
||||||
home-manager.useGlobalPkgs = true;
|
|
||||||
home-manager.useUserPackages = true;
|
|
||||||
home-manager.users.elias = import ./home.nix;
|
|
||||||
|
|
||||||
# Optionally, use home-manager.extraSpecialArgs to pass
|
|
||||||
# arguments to home.nix
|
|
||||||
} #close homemanager
|
|
||||||
]; #close modules
|
|
||||||
}; # close bluenix
|
|
||||||
|
|
||||||
}; #close nixosconfigurations
|
|
||||||
}; #close outputs
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,45 +0,0 @@
|
||||||
# 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, ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
imports =
|
|
||||||
[ # Include the results of the hardware scan.
|
|
||||||
./hardware-configuration.nix
|
|
||||||
];
|
|
||||||
|
|
||||||
# Bootloader.
|
|
||||||
boot.initrd.luks.devices."luks-b665cacd-d82b-44cd-ab4a-61018efec103".device = "/dev/disk/by-uuid/b665cacd-d82b-44cd-ab4a-61018efec103";
|
|
||||||
|
|
||||||
networking.hostName = "aspirenix"; # Define your hostname.
|
|
||||||
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
|
|
||||||
|
|
||||||
# Configure network proxy if necessary
|
|
||||||
# networking.proxy.default = "http://user:password@proxy:port/";
|
|
||||||
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
|
|
||||||
|
|
||||||
# Enable touchpad support (enabled default in most desktopManager).
|
|
||||||
# services.xserver.libinput.enable = true;
|
|
||||||
|
|
||||||
# Define a user account. Don't forget to set a password with ‘passwd’.
|
|
||||||
users.users.elias = {
|
|
||||||
isNormalUser = true;
|
|
||||||
description = "Elias Gasparis";
|
|
||||||
extraGroups = [ "networkmanager" "wheel" ];
|
|
||||||
packages = with pkgs; [
|
|
||||||
# thunderbird
|
|
||||||
htop
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
# 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. It‘s 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 = "24.11"; # Did you read the comment?
|
|
||||||
|
|
||||||
}
|
|
|
@ -1,44 +0,0 @@
|
||||||
# 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" "ehci_pci" "ahci" "usb_storage" "uas" "sd_mod" "rtsx_usb_sdmmc" ];
|
|
||||||
boot.initrd.kernelModules = [ ];
|
|
||||||
boot.kernelModules = [ "kvm-intel" ];
|
|
||||||
boot.extraModulePackages = [ ];
|
|
||||||
|
|
||||||
zramSwap.enable = true;
|
|
||||||
|
|
||||||
fileSystems."/" =
|
|
||||||
{ device = "/dev/disk/by-uuid/f4554a8a-b8d9-4c9e-bea9-c39452383e62";
|
|
||||||
fsType = "ext4";
|
|
||||||
};
|
|
||||||
|
|
||||||
boot.initrd.luks.devices."luks-8ae34699-9999-47dc-bc01-269b01f7c9bc".device = "/dev/disk/by-uuid/8ae34699-9999-47dc-bc01-269b01f7c9bc";
|
|
||||||
|
|
||||||
fileSystems."/boot" =
|
|
||||||
{ device = "/dev/disk/by-uuid/E0DA-830C";
|
|
||||||
fsType = "vfat";
|
|
||||||
options = [ "fmask=0077" "dmask=0077" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
swapDevices =
|
|
||||||
[ { device = "/dev/disk/by-uuid/fcd6ecf9-3d4d-4cb1-b217-957bae8fbc3f"; }
|
|
||||||
];
|
|
||||||
|
|
||||||
# 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.wlp2s0.useDHCP = lib.mkDefault true;
|
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
|
||||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
|
||||||
}
|
|
|
@ -1,52 +0,0 @@
|
||||||
# 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’).
|
|
||||||
|
|
||||||
# BLUENIX CONFIG FILE
|
|
||||||
|
|
||||||
{ config, pkgs, ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
imports =
|
|
||||||
[ # Include the results of the hardware scan.
|
|
||||||
./hardware-configuration.nix
|
|
||||||
];
|
|
||||||
|
|
||||||
# to make epson work
|
|
||||||
hardware.sane.enable = true; # enables support for SANE scanners
|
|
||||||
|
|
||||||
zramSwap.enable = true;
|
|
||||||
|
|
||||||
networking.hostName = "bluenix"; # Define your hostname.
|
|
||||||
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
|
|
||||||
|
|
||||||
hardware.bluetooth.enable = true;
|
|
||||||
|
|
||||||
# Enable touchpad support (enabled default in most desktopManager).
|
|
||||||
# services.xserver.libinput.enable = true;
|
|
||||||
|
|
||||||
# Define a user account. Don't forget to set a password with ‘passwd’.
|
|
||||||
users.users.elias = {
|
|
||||||
isNormalUser = true;
|
|
||||||
description = "Elias Gasparis";
|
|
||||||
extraGroups = [ "networkmanager" "wheel" "scanner"];
|
|
||||||
packages = with pkgs; [
|
|
||||||
# thunderbird
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
# Open ports in the firewall.
|
|
||||||
networking.firewall.allowedTCPPorts = [ 22 ];
|
|
||||||
# networking.firewall.allowedUDPPorts = [ ... ];
|
|
||||||
# Or disable the firewall altogether.
|
|
||||||
# networking.firewall.enable = false;
|
|
||||||
|
|
||||||
# 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. It‘s 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 = "24.05"; # Did you read the comment?
|
|
||||||
|
|
||||||
}
|
|
|
@ -1,40 +0,0 @@
|
||||||
# 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" "sd_mod" ];
|
|
||||||
boot.initrd.kernelModules = [ ];
|
|
||||||
boot.kernelModules = [ "kvm-intel" ];
|
|
||||||
boot.extraModulePackages = [ ];
|
|
||||||
|
|
||||||
fileSystems."/" =
|
|
||||||
{ device = "/dev/disk/by-uuid/9bd500b5-1d06-4ccf-b7c2-5338e8555a5a";
|
|
||||||
fsType = "ext4";
|
|
||||||
};
|
|
||||||
|
|
||||||
boot.initrd.luks.devices."luks-6cfc6952-9e66-4e10-b181-97278f99bf2f".device = "/dev/disk/by-uuid/6cfc6952-9e66-4e10-b181-97278f99bf2f";
|
|
||||||
|
|
||||||
fileSystems."/boot" =
|
|
||||||
{ device = "/dev/disk/by-uuid/4F9E-9FFF";
|
|
||||||
fsType = "vfat";
|
|
||||||
options = [ "fmask=0077" "dmask=0077" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
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.wlp2s0.useDHCP = lib.mkDefault true;
|
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
|
||||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
|
||||||
}
|
|
Loading…
Add table
Add a link
Reference in a new issue