refactor: move my stuff out of shared

This commit is contained in:
Moritz Böhme 2025-05-01 20:37:27 +02:00
parent d4eaf3ea49
commit e1d0d8e427
No known key found for this signature in database
GPG key ID: 970C6E89EB0547A9
5 changed files with 31 additions and 23 deletions

View file

@ -7,6 +7,7 @@
./hardware-configuration.nix
./disko.nix
../../modules/moritz/default.nix
../../modules/moritz/shared.nix
../../modules/shared.nix
];

View file

@ -9,6 +9,7 @@
imports = [
./disko.nix
../../modules/moritz/default.nix
../../modules/moritz/shared.nix
../../modules/shared.nix
];

View file

@ -2,6 +2,7 @@
imports = [
../../modules/zfs_unencrypted.nix
../../modules/shared.nix
../../modules/moritz/shared.nix
];
time.timeZone = "Europe/Berlin";

27
modules/moritz/shared.nix Normal file
View file

@ -0,0 +1,27 @@
{
config,
clan-core,
...
}: {
imports = [
clan-core.clanModules.user-password
clan-core.clanModules.root-password
clan-core.clanModules.user-password
];
# generate a random password for our user below
# can be read using `clan secrets get <machine-name>-user-password` command
clan.user-password.user = "moritz";
users.users.moritz = {
isNormalUser = true;
extraGroups = [
"wheel"
"networkmanager"
"video"
"input"
];
uid = 1000;
openssh.authorizedKeys.keys = config.users.users.root.openssh.authorizedKeys.keys;
};
}

View file

@ -1,12 +1,6 @@
{
config,
clan-core,
...
}: {
{clan-core, ...}: {
imports = [
clan-core.clanModules.sshd
clan-core.clanModules.root-password
clan-core.clanModules.user-password
clan-core.clanModules.state-version
clan-core.clanModules.static-hosts
clan-core.clanModules.machine-id
@ -16,20 +10,4 @@
# Locale service discovery and mDNS
services.avahi.enable = true;
# generate a random password for our user below
# can be read using `clan secrets get <machine-name>-user-password` command
clan.user-password.user = "moritz";
users.users.moritz = {
isNormalUser = true;
extraGroups = [
"wheel"
"networkmanager"
"video"
"input"
];
uid = 1000;
openssh.authorizedKeys.keys = config.users.users.root.openssh.authorizedKeys.keys;
};
}