ClanModules: add admin module
This commit is contained in:
4
clanModules/admin/README.md
Normal file
4
clanModules/admin/README.md
Normal file
@@ -0,0 +1,4 @@
|
||||
---
|
||||
description = "Convenient Administration for the Clan App"
|
||||
categories = ["administration"]
|
||||
---
|
||||
17
clanModules/admin/default.nix
Normal file
17
clanModules/admin/default.nix
Normal file
@@ -0,0 +1,17 @@
|
||||
{ lib, config, ... }:
|
||||
{
|
||||
options.clan.admin = {
|
||||
allowedKeys = lib.mkOption {
|
||||
default = [ ];
|
||||
type = lib.types.listOf lib.types.str;
|
||||
description = "The allowed public keys for ssh access to the admin user";
|
||||
};
|
||||
};
|
||||
imports = [
|
||||
../sshd
|
||||
../root-password
|
||||
];
|
||||
config = {
|
||||
users.users.root.openssh.authorizedKeys.keys = config.clan.admin.allowedKeys;
|
||||
};
|
||||
}
|
||||
1
clanModules/admin/roles/default.nix
Normal file
1
clanModules/admin/roles/default.nix
Normal file
@@ -0,0 +1 @@
|
||||
{ }
|
||||
@@ -1,6 +1,7 @@
|
||||
{ ... }:
|
||||
{
|
||||
flake.clanModules = {
|
||||
admin = ./admin;
|
||||
borgbackup = ./borgbackup;
|
||||
borgbackup-static = ./borgbackup-static;
|
||||
deltachat = ./deltachat;
|
||||
|
||||
Reference in New Issue
Block a user