This commit is contained in:
Greg Burd 2023-09-28 15:29:12 -04:00
parent 825ce66d15
commit 24a97b7d23
No known key found for this signature in database
GPG key ID: 1FC1E7793410DE46
2 changed files with 9 additions and 11 deletions

4
NOTES
View file

@ -80,7 +80,8 @@ swapDevices = [ { device = "/dev/disk/by-label/swap/swapfile"; } ];
nixos-rebulid switch
export NIX_CONFIG="experimental-features = nix-command flakes"
nix-env -iA nixos.pinentry nixos.git
nix-env -iA nixos.pinentry nixos.git nixos.direnv
eval "$(direnv hook bash)"
echo pinentry-program $(which pinentry) >> ~/.gnupg/gpg-agent.conf
git clone https://github.com/gburd/nix-config.git
cd nix-config
@ -98,6 +99,7 @@ home-manager switch --flake .#username@hostname
sudo nixos-rebuild switch --flake .#my-hostname
clear; sudo nixos-rebuild dry-activate --flake .#${hostname}
sudo nix --extra-experimental-features "flakes nix-command" run github:nix-community/disko -- --mode disko nixos/${hostname}/disks.nix --arg disks '[ "/dev/nvme0n1" ]' --arg config.networking.hostName ${hostname}
sudo nix run github:nix-community/disko -- --mode disko nixos/${hostname}/disks.nix
-------
services.pcscd.enable = true;

View file

@ -1,8 +1,4 @@
{ config, disk ? "/dev/nvme0n1", ... }:
let
hostname = config.networking.hostName;
in
{
{ disk ? "/dev/nvme0n1", ... }: {
disko.devices = {
disk = {
nvme = {
@ -34,23 +30,23 @@ in
type = "btrfs";
extraArgs = [ "-f" ];
subvolumes = {
"/root" = {
"root" = {
mountpoint = "/";
mountOptions = [ "compress=zstd" ];
};
"/home" = {
"home" = {
mountpoint = "/home";
mountOptions = [ "compress=zstd" ];
};
"/nix" = {
"nix" = {
mountpoint = "/nix";
mountOptions = [ "compress=zstd" "noatime" ];
};
"/persist" = {
"persist" = {
mountpoint = "/persist";
mountOptions = [ "compress=zstd" ];
};
"/var/logs" = {
"logs" = {
mountpoint = "/var/logs";
mountOptions = [ "compress=zstd" "noatime" ];
};