some work
This commit is contained in:
parent
2c6f0762ea
commit
9107892589
8 changed files with 74 additions and 4 deletions
23
flake.nix
23
flake.nix
|
@ -22,7 +22,13 @@
|
||||||
|
|
||||||
lanzaboote = {
|
lanzaboote = {
|
||||||
url = "github:nix-community/lanzaboote/v0.4.1";
|
url = "github:nix-community/lanzaboote/v0.4.1";
|
||||||
inputs.nixpkgs.follows = "nixpkgs-stable";
|
inputs.nixpkgs.follows = "nixpkgs-unstable";
|
||||||
|
};
|
||||||
|
|
||||||
|
authentik-nix = {
|
||||||
|
url = "github:nix-community/authentik-nix";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs-unstable";
|
||||||
|
# inputs.flake-parts.follows
|
||||||
};
|
};
|
||||||
|
|
||||||
tmux-yank = {
|
tmux-yank = {
|
||||||
|
@ -34,6 +40,7 @@
|
||||||
outputs =
|
outputs =
|
||||||
inputs@{
|
inputs@{
|
||||||
self,
|
self,
|
||||||
|
authentik-nix,
|
||||||
flake-utils,
|
flake-utils,
|
||||||
lanzaboote,
|
lanzaboote,
|
||||||
microvm,
|
microvm,
|
||||||
|
@ -90,6 +97,7 @@
|
||||||
specialArgs = { inherit inputs; };
|
specialArgs = { inherit inputs; };
|
||||||
modules = [
|
modules = [
|
||||||
sops-nix.nixosModules.sops
|
sops-nix.nixosModules.sops
|
||||||
|
microvm.nixosModules.host
|
||||||
|
|
||||||
./hosts/minime
|
./hosts/minime
|
||||||
./modules/basic-tools
|
./modules/basic-tools
|
||||||
|
@ -98,7 +106,20 @@
|
||||||
./modules/wg
|
./modules/wg
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
authentik = nixpkgs-stable.lib.nixosSystem {
|
||||||
|
system = "x84_64-linux";
|
||||||
|
specialArgs = { inherit inputs; };
|
||||||
|
modules = [
|
||||||
|
sops-nix.nixosModules.sops
|
||||||
|
microvm.nixosModules.microvm
|
||||||
|
authentik-nix.nixosModules.default
|
||||||
|
|
||||||
|
./microvms/authentik
|
||||||
|
./modules/server
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
hydraJobs =
|
hydraJobs =
|
||||||
let
|
let
|
||||||
get-toplevel = (
|
get-toplevel = (
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
imports = [
|
imports = [
|
||||||
./configuration.nix
|
./configuration.nix
|
||||||
./hardware-configuration.nix
|
./hardware-configuration.nix
|
||||||
./networking.nix
|
./networking
|
||||||
./secrets.nix
|
./secrets.nix
|
||||||
./zfs.nix
|
./zfs.nix
|
||||||
];
|
];
|
||||||
|
|
24
hosts/minime/networking/default.nix
Normal file
24
hosts/minime/networking/default.nix
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
{ ... }: {
|
||||||
|
imports = [
|
||||||
|
./uplink.nix
|
||||||
|
./uvm.nix
|
||||||
|
];
|
||||||
|
|
||||||
|
networking.hostName = "minime"; # Define your hostname.
|
||||||
|
networking.useNetworkd = true;
|
||||||
|
networking.firewall.enable = true;
|
||||||
|
|
||||||
|
services.resolved = {
|
||||||
|
enable = true;
|
||||||
|
dnssec = "false";
|
||||||
|
fallbackDns = [
|
||||||
|
"9.9.9.9"
|
||||||
|
"2620:fe::fe"
|
||||||
|
"149.112.112.112"
|
||||||
|
"2620:fe::9"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
systemd.network.enable = true;
|
||||||
|
|
||||||
|
}
|
19
hosts/minime/networking/uvm.nix
Normal file
19
hosts/minime/networking/uvm.nix
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
{ ... }: {
|
||||||
|
systemd.network = {
|
||||||
|
netdevs."10-uvm-br" = {
|
||||||
|
netdevConfig = {
|
||||||
|
Kind = bridge;
|
||||||
|
Name = "uvm-br";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
networks."10-uvm-br" = {
|
||||||
|
matchConfig.Name = "uvm-br";
|
||||||
|
networkConfig = {
|
||||||
|
DHCPServer = false;
|
||||||
|
IPv6SendRA = true;
|
||||||
|
};
|
||||||
|
Address = [ ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
0
microvms/authentik/default.nix
Normal file
0
microvms/authentik/default.nix
Normal file
|
@ -1,8 +1,6 @@
|
||||||
{
|
{
|
||||||
lib,
|
lib,
|
||||||
config,
|
config,
|
||||||
self,
|
|
||||||
registry,
|
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
{
|
{
|
||||||
|
|
|
@ -23,6 +23,14 @@
|
||||||
publicIface = "enp1s0";
|
publicIface = "enp1s0";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
"authentik" = {
|
||||||
|
address = [
|
||||||
|
"10.89.88.2/24"
|
||||||
|
"fd31:185d:722f::2/48"
|
||||||
|
];
|
||||||
|
publicKey = "";
|
||||||
|
privateKeyFile = config.sops.secrets."wg/0xa-proxy".path;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
|
Loading…
Add table
Reference in a new issue