community.general.pritunl_org_info – List Pritunl Organizations using the Pritunl API
Note
This plugin is part of the community.general collection (version 3.8.1).
You might already have this collection installed if you are using the ansible
package. 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 community.general
.
To use it in a playbook, specify: community.general.pritunl_org_info
.
New in version 2.5.0: of community.general
Synopsis
- A module to list Pritunl organizations using the Pritunl API.
Parameters
Parameter | Choices/Defaults | Comments |
---|---|---|
organization string | Name of the Pritunl organization to search for. If none provided, the module will return all Pritunl organizations. aliases: org | |
pritunl_api_secret string / required | API Secret found in Administrators > USERNAME > API Secret. | |
pritunl_api_token string / required | API Token of a Pritunl admin user. It needs to be enabled in Administrators > USERNAME > Enable Token Authentication. | |
pritunl_url string / required | URL and port of the Pritunl server on which the API is enabled. | |
validate_certs boolean |
| If certificates should be validated or not. This should never be set to false , except if you are very sure that your connection to the server can not be subject to a Man In The Middle attack. |
Examples
- name: List all existing Pritunl organizations community.general.pritunl_org_info: - name: Search for an organization named MyOrg community.general.pritunl_user_info: organization: MyOrg
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key | Returned | Description |
---|---|---|
organizations list / elements=dictionary | success | List of Pritunl organizations. Sample: [{'auth_api': False, 'auth_secret': 'None', 'auth_token': 'None', 'id': 'csftwlu6uhralzi2dpmhekz3', 'name': 'FooOrg', 'user_count': 0}, {'auth_api': False, 'auth_secret': 'None', 'auth_token': 'None', 'id': '58070daee63f3b2e6e472c36', 'name': 'MyOrg', 'user_count': 3}, {'auth_api': False, 'auth_secret': 'None', 'auth_token': 'None', 'id': 'v1sncsxxybnsylc8gpqg85pg', 'name': 'BarOrg', 'user_count': 0}] |
Authors
- Florian Dambrine (@Lowess)
© 2012–2018 Michael DeHaan
© 2018–2021 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/latest/collections/community/general/pritunl_org_info_module.html