move stuff into common config
This commit is contained in:
parent
1c50282114
commit
71312d55b9
5 changed files with 34 additions and 61 deletions
|
@ -5,7 +5,18 @@
|
||||||
nixpkgs,
|
nixpkgs,
|
||||||
agenix,
|
agenix,
|
||||||
...
|
...
|
||||||
}: {
|
}: let
|
||||||
|
username = "leo";
|
||||||
|
stateVersion = "23.11";
|
||||||
|
in {
|
||||||
|
imports = [
|
||||||
|
(lib.mkAliasOptionModule ["hm"] ["home-manager" "users" username])
|
||||||
|
|
||||||
|
../programs/fish.nix
|
||||||
|
../programs/git.nix
|
||||||
|
../programs/starship
|
||||||
|
];
|
||||||
|
|
||||||
age = {
|
age = {
|
||||||
identityPaths = ["/etc/age/key"];
|
identityPaths = ["/etc/age/key"];
|
||||||
|
|
||||||
|
@ -39,6 +50,10 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
hm.home = {
|
||||||
|
inherit stateVersion;
|
||||||
|
};
|
||||||
|
|
||||||
home-manager = {
|
home-manager = {
|
||||||
useGlobalPkgs = true;
|
useGlobalPkgs = true;
|
||||||
useUserPackages = true;
|
useUserPackages = true;
|
||||||
|
@ -109,7 +124,19 @@
|
||||||
|
|
||||||
time.timeZone = "Europe/Paris";
|
time.timeZone = "Europe/Paris";
|
||||||
|
|
||||||
users.users.root.hashedPasswordFile = config.age.secrets.rootPassword.path;
|
users.users = {
|
||||||
|
"${username}" = {
|
||||||
|
isNormalUser = true;
|
||||||
|
shell = pkgs.fish;
|
||||||
|
extraGroups = ["networkmanager" "wheel" "video" "libvirtd"];
|
||||||
|
hashedPasswordFile = config.age.secrets.userPassword.path;
|
||||||
|
openssh.authorizedKeys.keys = [
|
||||||
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIN+7+KfdOrhcnHayxvOENUeMx8rE4XEIV/AxMHiaNUP8"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
root.hashedPasswordFile = config.age.secrets.rootPassword.path;
|
||||||
|
};
|
||||||
|
|
||||||
# This value determines the NixOS release from which the default
|
# This value determines the NixOS release from which the default
|
||||||
# settings for stateful data, like file locations and database versions
|
# settings for stateful data, like file locations and database versions
|
||||||
|
@ -117,5 +144,5 @@
|
||||||
# this value at the release version of the first install of this system.
|
# this value at the release version of the first install of this system.
|
||||||
# Before changing this value read the documentation for this option
|
# Before changing this value read the documentation for this option
|
||||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
||||||
system.stateVersion = lib.mkDefault "23.11"; # Did you read the comment?
|
system.stateVersion = lib.mkDefault stateVersion; # Did you read the comment?
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,30 +0,0 @@
|
||||||
{
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
config,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
username = "uku";
|
|
||||||
in {
|
|
||||||
imports = [
|
|
||||||
(lib.mkAliasOptionModule ["hm"] ["home-manager" "users" username])
|
|
||||||
|
|
||||||
../programs/fish.nix
|
|
||||||
../programs/git.nix
|
|
||||||
../programs/starship
|
|
||||||
];
|
|
||||||
|
|
||||||
hm.home.stateVersion = "23.11";
|
|
||||||
|
|
||||||
services.tailscale.extraUpFlags = ["--advertise-exit-node"];
|
|
||||||
|
|
||||||
users.users."${username}" = {
|
|
||||||
isNormalUser = true;
|
|
||||||
shell = pkgs.fish;
|
|
||||||
extraGroups = ["networkmanager" "wheel"];
|
|
||||||
hashedPasswordFile = config.age.secrets.userPassword.path;
|
|
||||||
openssh.authorizedKeys.keys = [
|
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIN+7+KfdOrhcnHayxvOENUeMx8rE4XEIV/AxMHiaNUP8"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -37,8 +37,6 @@
|
||||||
catppuccin.nixosModules.catppuccin
|
catppuccin.nixosModules.catppuccin
|
||||||
]
|
]
|
||||||
++ nixos;
|
++ nixos;
|
||||||
|
|
||||||
server = nixos ++ [../configs/server.nix];
|
|
||||||
in {
|
in {
|
||||||
flake.nixosConfigurations = mapNixOS {
|
flake.nixosConfigurations = mapNixOS {
|
||||||
fuji = {
|
fuji = {
|
||||||
|
@ -63,7 +61,7 @@ in {
|
||||||
etna = {
|
etna = {
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
modules =
|
modules =
|
||||||
server
|
nixos
|
||||||
++ (with inputs; [
|
++ (with inputs; [
|
||||||
api-rs.nixosModules.default
|
api-rs.nixosModules.default
|
||||||
ukubot-rs.nixosModules.default
|
ukubot-rs.nixosModules.default
|
||||||
|
|
|
@ -27,6 +27,8 @@
|
||||||
|
|
||||||
reposilite.enable = true;
|
reposilite.enable = true;
|
||||||
|
|
||||||
|
tailscale.extraUpFlags = ["--advertise-exit-node"];
|
||||||
|
|
||||||
vaultwarden = {
|
vaultwarden = {
|
||||||
enable = true;
|
enable = true;
|
||||||
config = {
|
config = {
|
||||||
|
|
|
@ -1,30 +1,6 @@
|
||||||
{
|
{
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
config,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
username = "leo";
|
|
||||||
in {
|
|
||||||
imports = [
|
|
||||||
(lib.mkAliasOptionModule ["hm"] ["home-manager" "users" username])
|
|
||||||
|
|
||||||
../../programs/fish.nix
|
|
||||||
../../programs/git.nix
|
|
||||||
../../programs/starship
|
|
||||||
];
|
|
||||||
|
|
||||||
hm.home.stateVersion = "23.11";
|
|
||||||
|
|
||||||
wsl = {
|
wsl = {
|
||||||
enable = true;
|
enable = true;
|
||||||
defaultUser = username;
|
defaultUser = "leo";
|
||||||
};
|
|
||||||
|
|
||||||
users.users."${username}" = {
|
|
||||||
isNormalUser = true;
|
|
||||||
shell = pkgs.fish;
|
|
||||||
extraGroups = ["wheel"];
|
|
||||||
hashedPasswordFile = config.age.secrets.userPassword.path;
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue