Skyler Grey | f08a619 | 2024-06-01 23:55:20 +0000 | [diff] [blame] | 1 | # SPDX-FileCopyrightText: 2024 Clicks Codes |
| 2 | # |
| 3 | # SPDX-License-Identifier: GPL-3.0-only |
| 4 | |
| 5 | { lib, config, ... }: |
| 6 | { |
| 7 | options = { |
| 8 | clicks.users.minion.enable = lib.mkOption { |
| 9 | type = lib.types.bool; |
Skyler Grey | 4bf2de5 | 2024-07-29 17:55:05 +0000 | [diff] [blame^] | 10 | default = config.clicks.defaults.enable; |
Skyler Grey | f08a619 | 2024-06-01 23:55:20 +0000 | [diff] [blame] | 11 | }; |
| 12 | }; |
| 13 | |
| 14 | config = lib.mkIf config.clicks.users.minion.enable { |
| 15 | nix.settings.trusted-users = [ "minion" ]; |
| 16 | clicks.users.deployers = [ "minion" ]; |
| 17 | |
| 18 | users.users.minion = { |
| 19 | isNormalUser = true; |
| 20 | group = "minion"; |
| 21 | |
| 22 | openssh.authorizedKeys.keys = [ |
| 23 | "sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIIteIdlZv52nUDxW2SUsoJ2NZi/w9j1NZwuHanQ/o/DuAAAAHnNzaDpjb2xsYWJvcmFfeXViaWtleV9yZXNpZGVudA== collabora_yubikey_resident" |
| 24 | "sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIJRzQbQjXFpHKtt8lpNKmoNx57+EJ/z3wnKOn3/LjM6cAAAAFXNzaDppeXViaWtleV9yZXNpZGVudA== iyubikey_resident" |
| 25 | "sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIOhzJ0p9bFRSURUjV05rrt5jCbxPXke7juNbEC9ZJXS/AAAAGXNzaDp0aW55X3l1YmlrZXlfcmVzaWRlbnQ= tiny_yubikey_resident" |
| 26 | ]; |
| 27 | }; |
| 28 | |
| 29 | users.groups.minion = { }; |
| 30 | }; |
| 31 | } |