Compare commits
2 Commits
434901d813
...
68843be871
| Author | SHA1 | Date | |
|---|---|---|---|
| 68843be871 | |||
| e5d25d27a9 |
49
README.md
49
README.md
@@ -1,31 +1,23 @@
|
|||||||
# 0x29a nixos config
|
# 0x29a nixos config
|
||||||
|
|
||||||
personal nixos configuration files
|
My personal nixos configuration files.
|
||||||
|
|
||||||
## how to deploy the config
|
|
||||||
|
|
||||||
```bash
|
|
||||||
$ sudo nixos-rebuild switch --flake path:/home/aaron/git/nixconfig#default
|
|
||||||
```
|
|
||||||
|
|
||||||
## how to upgrade the system
|
|
||||||
|
|
||||||
```bash
|
|
||||||
$ sudo nixos-rebuild switch --flake --upgrade path:/home/aaron/git/nixconfig#default
|
|
||||||
```
|
|
||||||
|
|
||||||
## basic system installation
|
## basic system installation
|
||||||
|
|
||||||
1. the partitioning layout will look like this.
|
- The installations in this repository are always luks encrypted
|
||||||
|
- For simplicity I'm using device labels rather than uuids
|
||||||
|
|
||||||
|
1. the partitioning layout should look somewhat like this after the installation
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
|
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
|
||||||
sda 8:0 0 233.8G 0 disk
|
nvme0n1 259:0 0 476.9G 0 disk
|
||||||
├─sda1 8:1 0 500M 0 part /boot
|
├─nvme0n1p1 259:1 0 2G 0 part /boot
|
||||||
└─sda2 8:2 0 233.3G 0 part
|
└─nvme0n1p2 259:2 0 474.9G 0 part
|
||||||
└─root 254:0 0 233.3G 0 crypt
|
└─cryptroot 254:0 0 474.9G 0 crypt
|
||||||
├─vg-swap 254:1 0 8G 0 lvm [SWAP]
|
├─lvmroot-swap 254:1 0 20G 0 lvm [SWAP]
|
||||||
└─vg-root 254:2 0 225.3G 0 lvm /
|
├─lvmroot-home 254:2 0 250G 0 lvm /home
|
||||||
|
└─lvmroot-root 254:3 0 204.9G 0 lvm /nix/store
|
||||||
```
|
```
|
||||||
|
|
||||||
2. prepare the installation
|
2. prepare the installation
|
||||||
@@ -105,17 +97,18 @@ cd /mnt
|
|||||||
sudo nixos-install
|
sudo nixos-install
|
||||||
```
|
```
|
||||||
|
|
||||||
## how to install updates
|
## how to deploy the config
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# update flakes
|
$ sudo nixos-rebuild switch --flake .#host_name
|
||||||
nix flake update
|
```
|
||||||
|
|
||||||
# rebuild system
|
## how to upgrade the system
|
||||||
sudo nixos-rebuild switch --flake ~/git/nixconfig#default
|
|
||||||
|
|
||||||
# update home-manager files
|
```bash
|
||||||
home-manager switch --flake ~/git/nixconfig#aaron
|
$ cd /path/to/repo
|
||||||
|
$ sudo nix flake update
|
||||||
|
$ sudo nixos-rebuild switch --flake .#host_name
|
||||||
```
|
```
|
||||||
|
|
||||||
## author
|
## author
|
||||||
|
|||||||
35
flake.nix
35
flake.nix
@@ -1,41 +1,35 @@
|
|||||||
{
|
{
|
||||||
description = "0x29a NixOS flake config";
|
description = "0x29a ecosystem NixOS flake";
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
|
|
||||||
# the main nix package collection
|
# the main nix package collection
|
||||||
nixpkgs = {
|
nixpkgs = {
|
||||||
url = "github:nixos/nixpkgs/nixos-unstable";
|
url = "github:nixos/nixpkgs/nixos-unstable";
|
||||||
};
|
};
|
||||||
|
|
||||||
# home manager for dotfiles
|
# home manager for dotfiles
|
||||||
home-manager = {
|
home-manager = {
|
||||||
url = "github:nix-community/home-manager";
|
url = "github:nix-community/home-manager";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
# noctalia shell
|
# noctalia shell
|
||||||
noctalia = {
|
noctalia = {
|
||||||
url = "github:noctalia-dev/noctalia-shell";
|
url = "github:noctalia-dev/noctalia-shell";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = inputs@{ self, nixpkgs, home-manager, ... }:
|
outputs = inputs@{self, nixpkgs, home-manager, ... }: let
|
||||||
let
|
lib = nixpkgs.lib;
|
||||||
lib = nixpkgs.lib;
|
system = "x86_64-linux";
|
||||||
system = "x86_64-linux";
|
pkgs = nixpkgs.legacyPackages.${system};
|
||||||
pkgs = nixpkgs.legacyPackages.${system};
|
in {
|
||||||
in {
|
|
||||||
nixosConfigurations = {
|
nixosConfigurations = {
|
||||||
|
|
||||||
# default config
|
# default config
|
||||||
default = nixpkgs.lib.nixosSystem {
|
default = nixpkgs.lib.nixosSystem {
|
||||||
inherit system;
|
inherit system;
|
||||||
specialArgs = {
|
specialArgs = {
|
||||||
inherit inputs;
|
inherit inputs;
|
||||||
};
|
};
|
||||||
modules = [
|
modules = [
|
||||||
# import host specific configs
|
# import host specific configs
|
||||||
./hosts/default/configuration.nix
|
./hosts/default/configuration.nix
|
||||||
@@ -47,9 +41,9 @@
|
|||||||
# laptop neon
|
# laptop neon
|
||||||
neon = nixpkgs.lib.nixosSystem {
|
neon = nixpkgs.lib.nixosSystem {
|
||||||
inherit system;
|
inherit system;
|
||||||
specialArgs = {
|
specialArgs = {
|
||||||
inherit inputs;
|
inherit inputs;
|
||||||
};
|
};
|
||||||
modules = [
|
modules = [
|
||||||
# import host specific configs
|
# import host specific configs
|
||||||
./hosts/neon/configuration.nix
|
./hosts/neon/configuration.nix
|
||||||
@@ -57,9 +51,16 @@
|
|||||||
./hosts/neon/hardware-configuration.nix
|
./hosts/neon/hardware-configuration.nix
|
||||||
# import noctalia shell configs
|
# import noctalia shell configs
|
||||||
./hosts/neon/noctalia.nix
|
./hosts/neon/noctalia.nix
|
||||||
|
# Add home-manager form my user as a module
|
||||||
|
home-manager.nixosModules.home-manager
|
||||||
|
{
|
||||||
|
home-manager.useGlobalPkgs = true;
|
||||||
|
home-manager.useUserPackages = true;
|
||||||
|
home-manager.users.aaron = import ./hosts/neon/home.nix;
|
||||||
|
home-manager.extraSpecialArgs = { inherit inputs; };
|
||||||
|
}
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,12 +1,9 @@
|
|||||||
# 0x29a nixos conifg
|
|
||||||
|
|
||||||
{ pkgs, lib, inputs, ... }:
|
{ pkgs, lib, inputs, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
imports =
|
imports =
|
||||||
[
|
[
|
||||||
./hardware-configuration.nix
|
./hardware-configuration.nix
|
||||||
inputs.home-manager.nixosModules.home-manager
|
|
||||||
];
|
];
|
||||||
|
|
||||||
# use flakes
|
# use flakes
|
||||||
@@ -149,9 +146,6 @@
|
|||||||
home-manager.useUserPackages = true;
|
home-manager.useUserPackages = true;
|
||||||
home-manager.backupFileExtension = "backup";
|
home-manager.backupFileExtension = "backup";
|
||||||
|
|
||||||
# Add the user's home-manager configuration
|
|
||||||
home-manager.users.aaron = import ./home.nix;
|
|
||||||
|
|
||||||
# install state version
|
# install state version
|
||||||
system.stateVersion = "25.11"; # Don't change
|
system.stateVersion = "25.11"; # Don't change
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -8,7 +8,6 @@
|
|||||||
# user packages
|
# user packages
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
discord
|
discord
|
||||||
#teamspeak3 # unmaintained qtwebkit
|
|
||||||
fastfetch
|
fastfetch
|
||||||
screenfetch
|
screenfetch
|
||||||
zip
|
zip
|
||||||
@@ -44,6 +43,7 @@
|
|||||||
usbutils
|
usbutils
|
||||||
powerline-fonts
|
powerline-fonts
|
||||||
powerline-symbols
|
powerline-symbols
|
||||||
|
nerd-fonts.sauce-code-pro
|
||||||
];
|
];
|
||||||
|
|
||||||
# configure git
|
# configure git
|
||||||
@@ -61,6 +61,7 @@
|
|||||||
oh-my-zsh = {
|
oh-my-zsh = {
|
||||||
enable = true;
|
enable = true;
|
||||||
theme = "agnoster";
|
theme = "agnoster";
|
||||||
|
#plugins = [ "git" "ssh-agent" ];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user