benschubert.infrastructure.authentik_token module – Allows administration of Authentik tokens
Note
This module is part of the benschubert.infrastructure collection (version 0.0.1).
It is not included in ansible-core
.
To check whether it is installed, run ansible-galaxy collection list
.
To install it, use: ansible-galaxy collection install benschubert.infrastructure
.
To use it in a playbook, specify: benschubert.infrastructure.authentik_token
.
Synopsis
This module allows the administration of Authentik tokens via the Authentik API.
See https://docs.goauthentik.io/docs/add-secure-apps/providers/oauth2/client_credentials
Parameters
Parameter |
Comments |
---|---|
The token used to authenticate against the Authentik server |
|
The URL at which to contact the Authentik server |
|
PEM formatted file that contains a CA certificate to be used for validation |
|
Whether the entity should exist or not Choices:
|
|
The timeout to set when contacting the Authentik Server. If your server is slow to respond, it might be necessary to bump this Default: |
|
The configuration for the specified token |
|
A description to attach to the token |
|
Whether the token expires or not Choices:
|
|
The unique identifier for the token |
|
The intended usage for the token:
Choices:
|
|
The primary key of the user owning the token |
|
If false, SSL certificates will not be validated. This should only set to false used on personally controlled sites using self-signed certificates. Choices:
|
Examples
- name: Create a token for user 2
benschubert.infrastructure.authentik_token:
authentik_token: <my-secret-token>
authentik_url: https://authentik.test/
token:
identifier: my-test-token
intent: app_password
user: 2
description: A token used during tests
expiring: false
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
---|---|
The information returned by the Authentik API Returned: always Sample: |