1
1
Fork 1
mirror of https://github.com/oddlama/nix-config.git synced 2025-10-10 14:50:40 +02:00

feat: update agenix-rekey (prevents frequent store path change which caused unnecessary microvm restarts)

This commit is contained in:
oddlama 2024-03-15 17:21:55 +01:00
parent a737071162
commit d4a932923d
No known key found for this signature in database
GPG key ID: 14EFE510775FE39A
4 changed files with 108 additions and 105 deletions

View file

@ -2,5 +2,6 @@ f: {
lib,
config,
...
}: f {
}:
f {
}

View file

@ -2,5 +2,6 @@ f: {
lib,
config,
...
}: f {
}:
f {
}

View file

@ -8,105 +8,106 @@ f: {
mkOption
types
;
in f {
options.nodes = mkOption {
default = {};
description = ''
'';
type = types.attrsOf (types.submodule (nodeSubmod: {
options = {
name = mkOption {
description = "The name of this node";
default = nodeSubmod.config._module.args.name;
readOnly = true;
type = types.str;
in
f {
options.nodes = mkOption {
default = {};
description = ''
'';
type = types.attrsOf (types.submodule (nodeSubmod: {
options = {
name = mkOption {
description = "The name of this node";
default = nodeSubmod.config._module.args.name;
readOnly = true;
type = types.str;
};
type = mkOption {
description = "TODO";
default = "normal";
type = types.enum ["normal" "microvm" "nixos-container"];
};
parent = mkOption {
description = "TODO guests ids (topology.node.<name>.id) ensure exists";
default = [];
type = types.listOf types.str;
};
disks = mkOption {
default = {};
type = types.attrsOf (types.submodule (submod: {
options = {
name = mkOption {
description = "The name of this disk";
default = submod.config._module.args.name;
readOnly = true;
type = types.str;
};
};
}));
};
interfaces = mkOption {
description = "TODO";
default = {};
type = types.attrsOf (types.submodule (submod: {
options = {
name = mkOption {
description = "The name of this interface";
type = types.str;
readOnly = true;
default = submod.config._module.args.name;
};
mac = mkOption {
description = "The MAC address of this interface, if known.";
default = null;
type = types.nullOr types.str;
};
addresses = mkOption {
description = "The configured address(es), or a descriptive string (like DHCP).";
type = types.listOf types.str;
};
network = mkOption {
description = ''
The global name of the attached/spanned network.
If this is given, this interface can be shown in the network graph.
'';
default = null;
type = types.nullOr types.str;
};
};
}));
};
firewallRules = mkOption {
description = "TODO";
default = {};
type = types.attrsOf (types.submodule (submod: {
options = {
name = mkOption {
description = "The name of this firewall rule";
type = types.str;
readOnly = true;
default = submod.config._module.args.name;
};
contents = mkOption {
description = "A human readable summary of this rule's effects";
type = types.lines;
};
};
}));
};
};
}));
};
type = mkOption {
description = "TODO";
default = "normal";
type = types.enum ["normal" "microvm" "nixos-container"];
};
parent = mkOption {
description = "TODO guests ids (topology.node.<name>.id) ensure exists";
default = [];
type = types.listOf types.str;
};
disks = mkOption {
default = {};
type = types.attrsOf (types.submodule (submod: {
options = {
name = mkOption {
description = "The name of this disk";
default = submod.config._module.args.name;
readOnly = true;
type = types.str;
};
};
}));
};
interfaces = mkOption {
description = "TODO";
default = {};
type = types.attrsOf (types.submodule (submod: {
options = {
name = mkOption {
description = "The name of this interface";
type = types.str;
readOnly = true;
default = submod.config._module.args.name;
};
mac = mkOption {
description = "The MAC address of this interface, if known.";
default = null;
type = types.nullOr types.str;
};
addresses = mkOption {
description = "The configured address(es), or a descriptive string (like DHCP).";
type = types.listOf types.str;
};
network = mkOption {
description = ''
The global name of the attached/spanned network.
If this is given, this interface can be shown in the network graph.
'';
default = null;
type = types.nullOr types.str;
};
};
}));
};
firewallRules = mkOption {
description = "TODO";
default = {};
type = types.attrsOf (types.submodule (submod: {
options = {
name = mkOption {
description = "The name of this firewall rule";
type = types.str;
readOnly = true;
default = submod.config._module.args.name;
};
contents = mkOption {
description = "A human readable summary of this rule's effects";
type = types.lines;
};
};
}));
};
};
}));
};
config = {
# TODO: assertions = []
};
}
config = {
# TODO: assertions = []
};
}