refactor: simplify config and remove hom-manager dependency
continuous-integration/drone/push Build is passing
continuous-integration/drone/push Build is passing
This commit is contained in:
Generated
-22
@@ -18,27 +18,6 @@
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"home-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1785119570,
|
||||
"narHash": "sha256-Rgs2xKnGLFWQscxUaXX07oyZeuMDOHEbqDOsgliLFGM=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "d4fd24667c8cbef124bb70a20380cab75ec8474d",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"ref": "release-26.05",
|
||||
"repo": "home-manager",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"microvm": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
@@ -79,7 +58,6 @@
|
||||
"root": {
|
||||
"inputs": {
|
||||
"flake-utils": "flake-utils",
|
||||
"home-manager": "home-manager",
|
||||
"microvm": "microvm",
|
||||
"nixpkgs": "nixpkgs"
|
||||
}
|
||||
|
||||
@@ -3,10 +3,6 @@
|
||||
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
|
||||
home-manager = {
|
||||
url = "github:nix-community/home-manager/release-26.05";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
flake-utils.url = "github:numtide/flake-utils";
|
||||
microvm = {
|
||||
url = "github:astro/microvm.nix";
|
||||
@@ -19,7 +15,6 @@
|
||||
self,
|
||||
nixpkgs,
|
||||
microvm,
|
||||
home-manager,
|
||||
flake-utils,
|
||||
}:
|
||||
let
|
||||
@@ -45,7 +40,6 @@
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
microvm.nixosModules.microvm
|
||||
home-manager.nixosModules.home-manager
|
||||
./nix/hosts/client/configuration.nix
|
||||
];
|
||||
specialArgs = {
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
lib,
|
||||
pkgs,
|
||||
publicKey,
|
||||
privateKey,
|
||||
username,
|
||||
defaultDNS,
|
||||
extraHosts,
|
||||
@@ -106,9 +105,15 @@ in
|
||||
startAgent = true;
|
||||
knownHostsFiles = [
|
||||
(pkgs.writeText "local.keys" ''
|
||||
abra.local ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIFD3rtSHGYWSrvVZe9VGQSa16EIawScFWmkBfGC0cebv
|
||||
abra.local ${publicKey}
|
||||
'')
|
||||
];
|
||||
extraConfig = ''
|
||||
Host abra.local
|
||||
HostName abra.local
|
||||
Port 22
|
||||
User ${username}
|
||||
'';
|
||||
};
|
||||
programs.git = {
|
||||
enable = true;
|
||||
@@ -136,23 +141,4 @@ in
|
||||
jq
|
||||
wget
|
||||
];
|
||||
|
||||
home-manager = {
|
||||
useGlobalPkgs = true;
|
||||
useUserPackages = true;
|
||||
users."${username}" =
|
||||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./home.nix
|
||||
];
|
||||
};
|
||||
# pass args to home-manager
|
||||
extraSpecialArgs = {
|
||||
publicKey = publicKey;
|
||||
privateKey = privateKey;
|
||||
serverIp = serverIp;
|
||||
username = username;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
isNormalUser = true;
|
||||
password = password;
|
||||
home = "/home/${username}";
|
||||
description = "Abra server user";
|
||||
description = "Abra user";
|
||||
extraGroups = [
|
||||
"wheel"
|
||||
"networkmanager"
|
||||
|
||||
Reference in New Issue
Block a user