Note
This plugin is part of the community.general collection (version 2.0.1).
To install it use: ansible-galaxy collection install community.general
.
To use it in a playbook, specify: community.general.tss
.
New in version 1.0.0: of community.general
The below requirements are needed on the local controller node that executes this lookup.
Parameter | Choices/Defaults | Configuration | Comments |
---|---|---|---|
_terms integer / required | The integer ID of the secret. | ||
api_path_uri string | Default: "/api/v1" | env:TSS_API_PATH_URI | The path to append to the base URL to form a valid REST API request. |
base_url string / required | ini entries: [tss_lookup] env:TSS_BASE_URL | The base URL of the server, e.g. https://localhost/SecretServer . | |
password string / required | ini entries: [tss_lookup] env:TSS_PASSWORD | The password associated with the supplied username. | |
token_path_uri string | Default: "/oauth2/token" | env:TSS_TOKEN_PATH_URI | The path to append to the base URL to form a valid OAuth2 Access Grant request. |
username string / required | ini entries: [tss_lookup] env:TSS_USERNAME | The username with which to request the OAuth2 Access Grant. |
- hosts: localhost vars: secret: "{{ lookup('community.general.tss', 1) }}" tasks: - ansible.builtin.debug: msg: > the password is {{ (secret['items'] | items2dict(key_name='slug', value_name='itemValue'))['password'] }}
Common return values are documented here, the following are the fields unique to this lookup:
Key | Returned | Description |
---|---|---|
_list list / elements=dictionary | success | The JSON responses to GET /secrets/{id} . |
© 2012–2018 Michael DeHaan
© 2018–2021 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/2.11/collections/community/general/tss_lookup.html