nixpkgs/nixos
Maximilian Bosch ecaf6aed02
nixos/privacyidea: add proper support for privacyidea-token-janitor
`privacyidea-token-janitor`[1] is a tool which helps to automate
maintenance of tokens. This is helpful to identify e.g. orphaned tokens,
i.e. tokens of users that were removed or tokens that were unused for a
longer period of time and apply actions to them (e.g. `disable` or
`delete`).

This patch adds two new things:

* A wrapper for `privacyidea-token-janitor` to make sure it's executable
  from CLI. To achieve this, it does a `sudo(8)` into the
  `privacyidea`-user and sets up the environment to make sure the
  configuration file can be found. With that, administrators can
  directly invoke it from the CLI without additional steps.

* An optional service is added which performs automatic cleanups of
  orphaned and/or unassigned tokens. Yes, the tool can do way more
  stuff, but I figured it's reasonable to have an automatic way to clean
  up tokens of users who were removed from the PI instance. Additional
  automation steps should probably be implemented in additional
  services (and are perhaps too custom to add them to this module).

[1] https://privacyidea.readthedocs.io/en/v3.7/workflows_and_tools/tools/index.html
2022-10-06 11:43:20 +02:00
..
doc Merge pull request #193498 from hercules-ci/nixos-doc-disambiguate-test-options 2022-10-04 21:35:49 +01:00
lib Merge pull request #193498 from hercules-ci/nixos-doc-disambiguate-test-options 2022-10-04 21:35:49 +01:00
maintainers nixos/*: md-convert hidden plaintext options 2022-08-31 16:32:54 +02:00
modules nixos/privacyidea: add proper support for privacyidea-token-janitor 2022-10-06 11:43:20 +02:00
tests Merge pull request #191491 from oxalica/fix/systemd-initrd-modprobe 2022-10-05 10:39:58 +02:00
COPYING
default.nix
README
release-combined.nix treewide: remove myself as maintainer from some pkgs 2022-08-03 14:17:51 +02:00
release-small.nix error: 'mysql' has been renamed to/replaced by 'mariadb' 2022-09-27 19:39:52 +02:00
release.nix nixos/testing: Embrace callTest 2022-09-24 17:38:09 +01:00

*** NixOS ***

NixOS is a Linux distribution based on the purely functional package
management system Nix.  More information can be found at
https://nixos.org/nixos and in the manual in doc/manual.