needed to commit to add hosts directory
This commit is contained in:
parent
55ae559afc
commit
1ef633b683
110
hosts/JWST/configuration.nix.bk
Normal file
110
hosts/JWST/configuration.nix.bk
Normal file
|
@ -0,0 +1,110 @@
|
||||||
|
# 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,
|
||||||
|
lib,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
imports = [
|
||||||
|
# Include the results of the hardware scan.
|
||||||
|
./hardware-configuration.nix
|
||||||
|
# ./secrets.nix
|
||||||
|
# <home-manager/nixos>
|
||||||
|
# <nixos-hardware/dell/xps/15-9520>
|
||||||
|
# <nixos-hardware/common/gpu/nvidia/disable.nix>
|
||||||
|
];
|
||||||
|
|
||||||
|
# Enable Flakes and the new command-line tool
|
||||||
|
# nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
||||||
|
|
||||||
|
# Pick only one of the below networking options.
|
||||||
|
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
|
||||||
|
networking.networkmanager.enable = true; # Easiest to use and most distros use this by default.
|
||||||
|
|
||||||
|
# Configure network proxy if necessary
|
||||||
|
# networking.proxy.default = "http://user:password@proxy:port/";
|
||||||
|
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
|
||||||
|
|
||||||
|
# Select internationalisation properties.
|
||||||
|
i18n.defaultLocale = "en_US.UTF-8";
|
||||||
|
console = {
|
||||||
|
font = "Lat2-Terminus16";
|
||||||
|
keyMap = "us";
|
||||||
|
};
|
||||||
|
|
||||||
|
# Enable CUPS to print documents.
|
||||||
|
services.printing.enable = true;
|
||||||
|
|
||||||
|
# Enable sound.
|
||||||
|
sound.enable = true;
|
||||||
|
|
||||||
|
users.users.tacocat = {
|
||||||
|
isNormalUser = true;
|
||||||
|
home = "/home/tacocat";
|
||||||
|
description = "Aria Nolan";
|
||||||
|
extraGroups = ["wheel" "networkmanager" "audio" "video" "bluetooth" "kvm"];
|
||||||
|
};
|
||||||
|
|
||||||
|
nix.settings.trusted-users = ["tacocat"];
|
||||||
|
|
||||||
|
environment = {
|
||||||
|
systemPackages = with pkgs; [
|
||||||
|
vim
|
||||||
|
];
|
||||||
|
defaultPackages = with pkgs; [
|
||||||
|
perl
|
||||||
|
rsync
|
||||||
|
strace
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
# environment.variables.EDITOR = "helix";
|
||||||
|
# environment.variables.GIT_SSH_COMMAND = "ssh -i ~/.ssh/git_school";
|
||||||
|
|
||||||
|
# programs.firefox.package = pkgs.latest.firefox-wayland;
|
||||||
|
# programs.firefox.enable = true;
|
||||||
|
|
||||||
|
xdg.portal = {
|
||||||
|
enable = true;
|
||||||
|
wlr.enable = true;
|
||||||
|
extraPortals = with pkgs; [
|
||||||
|
xdg-desktop-portal-wlr
|
||||||
|
xdg-desktop-portal-gtk
|
||||||
|
];
|
||||||
|
};
|
||||||
|
hardware.opengl.enable = true;
|
||||||
|
|
||||||
|
# List services that you want to enable:
|
||||||
|
# Enable the OpenSSH daemon.
|
||||||
|
services.openssh.enable = true;
|
||||||
|
services.pipewire.enable = true;
|
||||||
|
|
||||||
|
# Some programs need SUID wrappers, can be configured further or are
|
||||||
|
# started in user sessions.
|
||||||
|
# programs.mtr.enable = true;
|
||||||
|
# programs.gnupg.agent = {
|
||||||
|
# enable = true;
|
||||||
|
# enableSSHSupport = true;
|
||||||
|
# };
|
||||||
|
|
||||||
|
# Open ports in the firewall.
|
||||||
|
# networking.firewall.allowedTCPPorts = [ ... ];
|
||||||
|
# networking.firewall.allowedUDPPorts = [ ... ];
|
||||||
|
# Or disable the firewall altogether.
|
||||||
|
# networking.firewall.enable = false;
|
||||||
|
|
||||||
|
# Copy the NixOS configuration file and link it from the resulting system
|
||||||
|
# (/run/current-system/configuration.nix). This is useful in case you
|
||||||
|
# accidentally delete configuration.nix.
|
||||||
|
# system.copySystemConfiguration = true;
|
||||||
|
|
||||||
|
# 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 = "23.05"; # Did you read the comment?
|
||||||
|
}
|
114
hosts/JWST/flake.nix.bk
Normal file
114
hosts/JWST/flake.nix.bk
Normal file
|
@ -0,0 +1,114 @@
|
||||||
|
{
|
||||||
|
description = "Aria's NixOS Flake";
|
||||||
|
|
||||||
|
nixConfig = {
|
||||||
|
experimental-features = [ "nix-command" "flakes" ];
|
||||||
|
substituters = [
|
||||||
|
"https://cache.nixos.org/"
|
||||||
|
];
|
||||||
|
|
||||||
|
extra-substituters = [
|
||||||
|
# Nix community's cache server
|
||||||
|
"https://nix-community.cachix.org"
|
||||||
|
];
|
||||||
|
extra-trusted-public-keys = [
|
||||||
|
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
# This is the standard format for flake.nix.
|
||||||
|
# `inputs` are the dependencies of the flake,
|
||||||
|
# and `outputs` function will return all the build results of the flake.
|
||||||
|
# Each item in `inputs` will be passed as a parameter to
|
||||||
|
# the `outputs` function after being pulled and built.
|
||||||
|
inputs = {
|
||||||
|
# There are many ways to reference flake inputs.
|
||||||
|
# The most widely used is `github:owner/name/reference`,
|
||||||
|
# which represents the GitHub repository URL + branch/commit-id/tag.
|
||||||
|
|
||||||
|
# Official NixOS package source, using nixos-unstable branch here
|
||||||
|
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
||||||
|
# home-manager, used for managing user configuration
|
||||||
|
home-manager = {
|
||||||
|
url = "github:nix-community/home-manager/release-23.05";
|
||||||
|
# The `follows` keyword in inputs is used for inheritance.
|
||||||
|
# Here, `inputs.nixpkgs` of home-manager is kept consistent with
|
||||||
|
# the `inputs.nixpkgs` of the current flake,
|
||||||
|
# to avoid problems caused by different versions of nixpkgs.
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
|
||||||
|
neovim.url = "github:neovim/neovim/stable";
|
||||||
|
};
|
||||||
|
|
||||||
|
# `outputs` are all the build result of the flake.
|
||||||
|
#
|
||||||
|
# A flake can have many use cases and different types of outputs.
|
||||||
|
#
|
||||||
|
# parameters in function `outputs` are defined in `inputs` and
|
||||||
|
# can be referenced by their names. However, `self` is an exception,
|
||||||
|
# this special parameter points to the `outputs` itself(self-reference)
|
||||||
|
#
|
||||||
|
# The `@` syntax here is used to alias the attribute set of the
|
||||||
|
# inputs's parameter, making it convenient to use inside the function.
|
||||||
|
outputs = { self, nixpkgs, ... }@inputs: {
|
||||||
|
nixosConfigurations = {
|
||||||
|
# By default, NixOS will try to refer the nixosConfiguration with
|
||||||
|
# its hostname, so the system named `Voyager` will use this one.
|
||||||
|
# However, the configuration name can also be specified using:
|
||||||
|
# sudo nixos-rebuild switch --flake /path/to/flakes/directory#<name>
|
||||||
|
#
|
||||||
|
# The `nixpkgs.lib.nixosSystem` function is used to build this
|
||||||
|
# configuration, the following attribute set is its parameter.
|
||||||
|
#
|
||||||
|
# Run the following command in the flake's directory to
|
||||||
|
# deploy this configuration on any NixOS system:
|
||||||
|
# sudo nixos-rebuild switch --flake .#Voyager
|
||||||
|
"Voyager" = nixpkgs.lib.nixosSystem {
|
||||||
|
system = "x86_64-linux";
|
||||||
|
|
||||||
|
# The Nix module system can modularize configuration,
|
||||||
|
# improving the maintainability of configuration.
|
||||||
|
#
|
||||||
|
# Each parameter in the `modules` is a Nix Module, and
|
||||||
|
# there is a partial introduction to it in the nixpkgs manual:
|
||||||
|
# <https://nixos.org/manual/nixpkgs/unstable/#module-system-introduction>
|
||||||
|
# It is said to be partial because the documentation is not
|
||||||
|
# complete, only some simple introductions.
|
||||||
|
# such is the current state of Nix documentation...
|
||||||
|
#
|
||||||
|
# A Nix Module can be an attribute set, or a function that
|
||||||
|
# returns an attribute set. By default, if a Nix Module is a
|
||||||
|
# function, this function can only have the following parameters:
|
||||||
|
#
|
||||||
|
# lib: the nixpkgs function library, which provides many
|
||||||
|
# useful functions for operating Nix expressions:
|
||||||
|
# https://nixos.org/manual/nixpkgs/stable/#id-1.4
|
||||||
|
# config: all config options of the current flake, every useful
|
||||||
|
# options: all options defined in all NixOS Modules
|
||||||
|
# in the current flake
|
||||||
|
# pkgs: a collection of all packages defined in nixpkgs,
|
||||||
|
# plus a set of functions related to packaging.
|
||||||
|
# you can assume its default value is
|
||||||
|
# `nixpkgs.legacyPackages."${system}"` for now.
|
||||||
|
# can be customed by `nixpkgs.pkgs` option
|
||||||
|
# modulesPath: the default path of nixpkgs's modules folder,
|
||||||
|
# used to import some extra modules from nixpkgs.
|
||||||
|
# this parameter is rarely used,
|
||||||
|
# you can ignore it for now.
|
||||||
|
#
|
||||||
|
# Only these parameters can be passed by default.
|
||||||
|
# If you need to pass other parameters,
|
||||||
|
# you must use `specialArgs` by uncomment the following line:
|
||||||
|
#
|
||||||
|
# specialArgs = {...} # pass custom arguments into all sub module.
|
||||||
|
modules = [
|
||||||
|
# Import the configuration.nix here, so that the
|
||||||
|
# old configuration file can still take effect.
|
||||||
|
# Note: configuration.nix itself is also a Nix Module,
|
||||||
|
./configuration.nix
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
57
hosts/JWST/hardware-configuration.nix.bk
Normal file
57
hosts/JWST/hardware-configuration.nix.bk
Normal file
|
@ -0,0 +1,57 @@
|
||||||
|
# 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,
|
||||||
|
modulesPath,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
imports = [
|
||||||
|
(modulesPath + "/installer/scan/not-detected.nix")
|
||||||
|
];
|
||||||
|
|
||||||
|
boot.initrd.availableKernelModules = [
|
||||||
|
"xhci_pci"
|
||||||
|
"thunderbolt"
|
||||||
|
"rtsx_pci_sdmmc"
|
||||||
|
"nvme"
|
||||||
|
];
|
||||||
|
boot.initrd.kernelModules = [];
|
||||||
|
boot.kernelModules = ["kvm-intel" "nvme"];
|
||||||
|
boot.extraModulePackages = [];
|
||||||
|
boot.loader.efi.canTouchEfiVariables = true;
|
||||||
|
boot.loader.efi.efiSysMountPoint = "/boot/efi";
|
||||||
|
boot.loader.grub.efiSupport = true;
|
||||||
|
boot.loader.grub.device = "nodev";
|
||||||
|
boot.loader.grub.extraEntriesBeforeNixOS = true;
|
||||||
|
boot.loader.grub.extraEntries = ''
|
||||||
|
menuentry "Void" {
|
||||||
|
search --set=void --fs-uuid 987518fa-8ea0-49a6-b1e5-1fed4e4ae50f
|
||||||
|
configfile "($void)/boot/grub/grub.cfg"
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
|
||||||
|
networking.hostName = "JWST"; # Define your hostname.
|
||||||
|
|
||||||
|
fileSystems."/" = {
|
||||||
|
device = "/dev/disk/by-uuid/488c7ef3-5ea1-4a16-a5f9-e241901c24ce";
|
||||||
|
fsType = "ext4";
|
||||||
|
};
|
||||||
|
|
||||||
|
swapDevices = [
|
||||||
|
{device = "/dev/disk/by-uuid/802e89ce-52b8-41b9-85ea-b969ab08765f";}
|
||||||
|
];
|
||||||
|
|
||||||
|
# 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.virbr0.useDHCP = lib.mkDefault true;
|
||||||
|
# networking.interfaces.wlp0s20f3.useDHCP = lib.mkDefault true;
|
||||||
|
|
||||||
|
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||||
|
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
||||||
|
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||||
|
}
|
73
hosts/JWST/home.nix.bk
Normal file
73
hosts/JWST/home.nix.bk
Normal file
|
@ -0,0 +1,73 @@
|
||||||
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
|
||||||
|
imports = [ <home-manager/nixos> ];
|
||||||
|
|
||||||
|
# TODO please change the username & home direcotry to your own
|
||||||
|
home.username = "tacocat";
|
||||||
|
home.homeDirectory = "/home/tacocat";
|
||||||
|
|
||||||
|
# link the configuration file in current directory to the specified location in home directory
|
||||||
|
# home.file.".config/i3/wallpaper.jpg".source = ./wallpaper.jpg;
|
||||||
|
|
||||||
|
# link all files in `./scripts` to `~/.config/i3/scripts`
|
||||||
|
# home.file.".config/i3/scripts" = {
|
||||||
|
# source = ./scripts;
|
||||||
|
# recursive = true; # link recursively
|
||||||
|
# executable = true; # make all files executable
|
||||||
|
# };
|
||||||
|
|
||||||
|
# encode the file content in nix configuration file directly
|
||||||
|
# home.file.".xxx".text = ''
|
||||||
|
# xxx
|
||||||
|
# '';
|
||||||
|
|
||||||
|
# basic configuration of git, please change to your own
|
||||||
|
programs.git = {
|
||||||
|
enable = true;
|
||||||
|
userName = "Aria Nolan";
|
||||||
|
userEmail = "aria@chytrid.xyz";
|
||||||
|
};
|
||||||
|
|
||||||
|
# Packages that should be installed to the user profile.
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
firefox
|
||||||
|
thunderbird
|
||||||
|
vim
|
||||||
|
neovim
|
||||||
|
kitty
|
||||||
|
wget
|
||||||
|
tmux
|
||||||
|
helix
|
||||||
|
river
|
||||||
|
git
|
||||||
|
gcc
|
||||||
|
];
|
||||||
|
|
||||||
|
programs.bash = {
|
||||||
|
enable = true;
|
||||||
|
enableCompletion = true;
|
||||||
|
# TODO add your custom bashrc here
|
||||||
|
bashrcExtra = ''
|
||||||
|
export PATH="$PATH:$HOME/bin:$HOME/.local/bin:$HOME/go/bin"
|
||||||
|
'';
|
||||||
|
|
||||||
|
# set some aliases, feel free to add more or remove some
|
||||||
|
shellAliases = {
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
# This value determines the home Manager release that your
|
||||||
|
# configuration is compatible with. This helps avoid breakage
|
||||||
|
# when a new home Manager release introduces backwards
|
||||||
|
# incompatible changes.
|
||||||
|
#
|
||||||
|
# You can update home Manager without changing this value. See
|
||||||
|
# the home Manager release notes for a list of state version
|
||||||
|
# changes in each release.
|
||||||
|
home.stateVersion = "23.11";
|
||||||
|
|
||||||
|
# Let home Manager install and manage itself.
|
||||||
|
programs.home-manager.enable = true;
|
||||||
|
}
|
Loading…
Reference in a new issue