mirror of
https://github.com/gensokyo-zone/infrastructure.git
synced 2026-02-09 04:19:19 -08:00
chore(extern): keys
This commit is contained in:
parent
c51febd94d
commit
ac9441da3d
7 changed files with 29 additions and 5 deletions
|
|
@ -40,16 +40,21 @@
|
|||
};
|
||||
};
|
||||
mkNodeSystems = systems: mapAttrs (_: mkNodeSystem) systems;
|
||||
mkExtern = system: {
|
||||
mkExtern = system: let
|
||||
enabledFiles = filterAttrs (_: file: file.enable) system.extern.files;
|
||||
in {
|
||||
files = mapAttrs' (_: file: nameValuePair file.path {
|
||||
source = assert file.relativeSource != null; file.relativeSource;
|
||||
inherit (file) owner group mode;
|
||||
}) system.extern.files;
|
||||
}) enabledFiles;
|
||||
};
|
||||
mkNode = system: {
|
||||
users = mkNodeUsers templateUsers;
|
||||
systems = mkNodeSystems (nodeSystems system.config.name);
|
||||
extern = mkExtern system.config;
|
||||
ssh.root.authorizedKeys = {
|
||||
inherit (templateSystem.config.environment.etc."ssh/authorized_keys.d/root".source) text;
|
||||
};
|
||||
};
|
||||
mkNetwork = system: {
|
||||
inherit (system.config.access) hostName;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue