Big readme update and more
Updated readme with tons of information. Made kazuki a hercules agent. Fixed secrets ownerships. Started working on a custom installer iso. Changed helix theme.
This commit is contained in:
parent
ef44ff6943
commit
fb0c1a4451
17 changed files with 164 additions and 39 deletions
5
hosts/common/default.nix
Normal file
5
hosts/common/default.nix
Normal file
|
@ -0,0 +1,5 @@
|
|||
{
|
||||
imports = [
|
||||
./hercules.nix
|
||||
];
|
||||
}
|
24
hosts/common/hercules.nix
Normal file
24
hosts/common/hercules.nix
Normal file
|
@ -0,0 +1,24 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
options.common.hercules.enable = lib.mkEnableOption "Enables hercules-ci-agent with my configuration";
|
||||
|
||||
config = lib.mkIf config.common.hercules.enable {
|
||||
age.secrets.hercules-token = {
|
||||
file = ../../secrets/hercules-token.age;
|
||||
owner = config.systemd.services.hercules-ci-agent.serviceConfig.User;
|
||||
};
|
||||
|
||||
services.hercules-ci-agent = {
|
||||
enable = true;
|
||||
settings = {
|
||||
clusterJoinTokenPath = config.age.secrets.hercules-token.path;
|
||||
concurrentTasks = lib.mkDefault 4;
|
||||
binaryCachesPath = pkgs.writeText "empty-caches.json" "{}";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -43,7 +43,9 @@
|
|||
inputs.disko.nixosModules.disko
|
||||
inputs.mailserver.nixosModules.default
|
||||
inputs.home-manager.nixosModules.home-manager
|
||||
inputs.hercules-ci-agent.nixosModules.agent-service
|
||||
self.nixosModules.settei
|
||||
./common
|
||||
defaultOptions
|
||||
module
|
||||
];
|
||||
|
@ -55,5 +57,6 @@
|
|||
./kazuki
|
||||
./hijiri-vm
|
||||
# ./legion
|
||||
./installer
|
||||
];
|
||||
}
|
||||
|
|
15
hosts/installer/default.nix
Normal file
15
hosts/installer/default.nix
Normal file
|
@ -0,0 +1,15 @@
|
|||
{lib, ...}: {
|
||||
configurations.nixos = let
|
||||
mkInstaller = system: ({pkgs, ...}: {
|
||||
nixpkgs = {inherit system;};
|
||||
|
||||
environment.systemPackages = [pkgs.nixos-install-tools];
|
||||
|
||||
# Make nixos-anywhere treat this as a installer iso
|
||||
system.nixos.variant_id = "installer";
|
||||
});
|
||||
systems = ["aarch64-linux" "x86_64-linux"];
|
||||
installers = map (system: lib.nameValuePair "installer-${system}" (mkInstaller system)) systems;
|
||||
in
|
||||
lib.listToAttrs installers;
|
||||
}
|
|
@ -24,5 +24,7 @@
|
|||
loader.systemd-boot.configurationLimit = 1;
|
||||
loader.efi.canTouchEfiVariables = true;
|
||||
};
|
||||
|
||||
common.hercules.enable = true;
|
||||
};
|
||||
}
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
{config, ...}: {
|
||||
age.secrets.vault-cert-env.file = ../../secrets/vault-cert-env.age;
|
||||
age.secrets.vault-cert-env = {
|
||||
file = ../../secrets/vault-cert-env.age;
|
||||
owner = config.services.nginx.user;
|
||||
};
|
||||
|
||||
services.vaultwarden = {
|
||||
enable = true;
|
||||
|
|
|
@ -9,6 +9,7 @@ in {
|
|||
imports = [
|
||||
./hardware.nix
|
||||
# ./disks.nix
|
||||
./initrd.nix
|
||||
];
|
||||
|
||||
nixpkgs.system = "x86_64-linux";
|
||||
|
|
14
hosts/legion/initrd.nix
Normal file
14
hosts/legion/initrd.nix
Normal file
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
config,
|
||||
username,
|
||||
...
|
||||
}: {
|
||||
boot.initrd = {
|
||||
availableKernelModules = ["ath10k_pci" "r8169"];
|
||||
network.enable = true;
|
||||
network.ssh = {
|
||||
enable = true;
|
||||
authorizedKeys = config.users.users.${username}.openssh.authorizedKeys.keys;
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue