minimal bootstrap install

This commit is contained in:
Sam 2024-05-23 00:10:58 +01:00
parent 8679f14566
commit 1c0725912d
3 changed files with 12 additions and 12 deletions

View File

@ -14,7 +14,6 @@ in
# Import core options # Import core options
./hardware-configuration.nix ./hardware-configuration.nix
../common/core ../common/core
]; ];
nixpkgs = { nixpkgs = {

View File

@ -3,6 +3,7 @@ let
secretsDirectory = builtins.toString inputs.nix-secrets; secretsDirectory = builtins.toString inputs.nix-secrets;
secretsFile = "${secretsDirectory}/secrets.yaml"; secretsFile = "${secretsDirectory}/secrets.yaml";
hostname = config.networking.hostName; hostname = config.networking.hostName;
username = config.username;
in in
{ {
imports = [ imports = [
@ -16,10 +17,10 @@ in
age = { age = {
sshKeyPaths = [ "/etc/ssh/ssh_host_ed25519_key" ]; sshKeyPaths = [ "/etc/ssh/ssh_host_ed25519_key" ];
}; };
secrets = { secrets = builtins.merge ({
"passwords/root".neededForUsers = true; "passwords/root".neededForUsers = true;
"passwords/sam".neededForUsers = true; })
"passwords/media".neededForUsers = true; if username != null then { "passwords/${username}".neededForUsers = true; } else {};
}; };
}; };
} }

View File

@ -11,6 +11,9 @@ in
../common/optional/btrfs-impermanence.nix ../common/optional/btrfs-impermanence.nix
inputs.impermanence.nixosModules.impermanence inputs.impermanence.nixosModules.impermanence
# Create users for this host
../common/users/media
# Import core options # Import core options
./hardware-configuration.nix ./hardware-configuration.nix
../common/core ../common/core
@ -18,9 +21,6 @@ in
# Import optional options # Import optional options
../common/optional/openssh.nix ../common/optional/openssh.nix
# Create users for this host
../common/users/media
]; ];
nixpkgs = { nixpkgs = {
@ -48,7 +48,7 @@ in
"/etc/ssh/ssh_host_ed25519_key" "/etc/ssh/ssh_host_ed25519_key"
"/etc/ssh/ssh_host_ed25519_key.pub" "/etc/ssh/ssh_host_ed25519_key.pub"
]; ];
users.media = { users.${config.username} = {
directories = [ directories = [
"sync" "sync"
"keep" "keep"
@ -88,8 +88,8 @@ in
services = { services = {
qemuGuest.enable = true; qemuGuest.enable = true;
}; };
services.libinput.enable = true; #services.libinput.enable = true;
services.displayManager.defaultSession = "cinnamon"; #services.displayManager.defaultSession = "cinnamon";
# services.xserver = { # services.xserver = {
# enable = true; # enable = true;