mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-04-30 02:16:50 +00:00
Compare commits
48 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f5a2d32caa | ||
|
|
c11b7b4c86 | ||
|
|
cdbcf8abc7 | ||
|
|
2e781bf8c4 | ||
|
|
8f588ac745 | ||
|
|
7cd9b839c5 | ||
|
|
e4651c1bf3 | ||
|
|
0342cf1730 | ||
|
|
269df75421 | ||
|
|
bc32914424 | ||
|
|
21ad7c8bfa | ||
|
|
ae3fe51929 | ||
|
|
5d6047a21a | ||
|
|
c0d11f631f | ||
|
|
173c8b1dfa | ||
|
|
005db8177e | ||
|
|
8595601708 | ||
|
|
7229ef4ac4 | ||
|
|
5170c26ffd | ||
|
|
64049a35de | ||
|
|
3427e02fce | ||
|
|
f2e1abfe5e | ||
|
|
fc0d813d5f | ||
|
|
b51e008358 | ||
|
|
b32b69742b | ||
|
|
73ee9702db | ||
|
|
1cddae2265 | ||
|
|
ea2df93116 | ||
|
|
e646d21935 | ||
|
|
f522802977 | ||
|
|
3710f28efb | ||
|
|
2f24bcef8f | ||
|
|
6223b755e1 | ||
|
|
813c6e232d | ||
|
|
3e4aae56bd | ||
|
|
b099a465c5 | ||
|
|
d2b0a0d2bf | ||
|
|
fe0a5fd85f | ||
|
|
f3a2750205 | ||
|
|
5657889b28 | ||
|
|
1b2fbd72de | ||
|
|
5a2e7f9b1b | ||
|
|
c5ff49db56 | ||
|
|
43dc6ba533 | ||
|
|
eb1f0c28a9 | ||
|
|
41993d44e2 | ||
|
|
9345db2001 | ||
|
|
527417dce9 |
8
.github/BOTMETA.yml
vendored
8
.github/BOTMETA.yml
vendored
@@ -223,7 +223,8 @@ files:
|
||||
$lookups/dnstxt.py:
|
||||
maintainers: jpmens
|
||||
$lookups/dsv.py:
|
||||
maintainers: amigus endlesstrax delineaKrehl tylerezimmerman
|
||||
maintainers: delineaKrehl tylerezimmerman
|
||||
ignore: amigus
|
||||
$lookups/etcd3.py:
|
||||
maintainers: eric-belhomme
|
||||
$lookups/etcd.py:
|
||||
@@ -260,7 +261,8 @@ files:
|
||||
maintainers: RevBits
|
||||
$lookups/shelvefile.py: {}
|
||||
$lookups/tss.py:
|
||||
maintainers: amigus endlesstrax delineaKrehl tylerezimmerman
|
||||
maintainers: delineaKrehl tylerezimmerman
|
||||
ignore: amigus
|
||||
$module_utils/:
|
||||
labels: module_utils
|
||||
$module_utils/gconftool2.py:
|
||||
@@ -808,6 +810,8 @@ files:
|
||||
maintainers: bcoca matburt maxamillion
|
||||
$modules/packaging/language/pipx.py:
|
||||
maintainers: russoz
|
||||
$modules/packaging/language/pipx_info.py:
|
||||
maintainers: russoz
|
||||
$modules/packaging/language/yarn.py:
|
||||
maintainers: chrishoffman verkaufer
|
||||
$modules/packaging/os/apk.py:
|
||||
|
||||
@@ -6,6 +6,69 @@ Community General Release Notes
|
||||
|
||||
This changelog describes changes after version 4.0.0.
|
||||
|
||||
v5.6.0
|
||||
======
|
||||
|
||||
Release Summary
|
||||
---------------
|
||||
|
||||
Regular bugfix and feature release.
|
||||
|
||||
Minor Changes
|
||||
-------------
|
||||
|
||||
- ali_instance - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5240).
|
||||
- ali_instance_info - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5240).
|
||||
- consul_session - adds ``token`` parameter for session (https://github.com/ansible-collections/community.general/pull/5193).
|
||||
- gitlab module util - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_branch - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_deploy_key - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_group - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_group_members - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_group_variable - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_hook - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_hook - minor refactoring (https://github.com/ansible-collections/community.general/pull/5271).
|
||||
- gitlab_project - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_project_members - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_project_variable - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_protected_branch - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_runner - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_user - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- homebrew, homebrew_tap - added Homebrew on Linux path to defaults (https://github.com/ansible-collections/community.general/pull/5241).
|
||||
- nagios - minor refactoring on parameter validation for different actions (https://github.com/ansible-collections/community.general/pull/5239).
|
||||
- nmcli - add bond option ``xmit_hash_policy`` to bond options (https://github.com/ansible-collections/community.general/issues/5148).
|
||||
- nmcli - honor IP options for VPNs (https://github.com/ansible-collections/community.general/pull/5228).
|
||||
- redfish - added new command GetVirtualMedia, VirtualMediaInsert and VirtualMediaEject to Systems category due to Redfish spec changes the virtualMedia resource location from Manager to System (https://github.com/ansible-collections/community.general/pull/5124).
|
||||
- seport - added new argument ``local`` (https://github.com/ansible-collections/community.general/pull/5203)
|
||||
- wdc_redfish_command - add ``PowerModeLow`` and ``PowerModeNormal`` commands for ``Chassis`` category (https://github.com/ansible-collections/community.general/pull/5145).
|
||||
|
||||
Deprecated Features
|
||||
-------------------
|
||||
|
||||
- proxmox - deprecated the current ``unprivileged`` default value, will be changed to ``true`` in community.general 7.0.0 (https://github.com/pull/5224).
|
||||
|
||||
Bugfixes
|
||||
--------
|
||||
|
||||
- listen_ports_facts - removed leftover ``EnvironmentError`` . The ``else`` clause had a wrong indentation. The check is now handled in the ``split_pid_name`` function (https://github.com/ansible-collections/community.general/pull/5202).
|
||||
- nmcli - avoid changed status for most cases with VPN connections (https://github.com/ansible-collections/community.general/pull/5126).
|
||||
- osx_defaults - no longer expand ``~`` in ``value`` to the user's home directory, or expand environment variables (https://github.com/ansible-collections/community.general/issues/5234, https://github.com/ansible-collections/community.general/pull/5243).
|
||||
- proxmox_kvm - fix exception when no ``agent`` argument is specified (https://github.com/ansible-collections/community.general/pull/5194).
|
||||
- proxmox_kvm - replace new condition with proper condition to allow for using ``vmid`` on update (https://github.com/ansible-collections/community.general/pull/5206).
|
||||
- slack - fix message update for channels which start with ``CP``. When ``message-id`` was passed it failed for channels which started with ``CP`` because the ``#`` symbol was added before the ``channel_id`` (https://github.com/ansible-collections/community.general/pull/5249).
|
||||
- tss lookup plugin - adding support for updated Delinea library (https://github.com/DelineaXPM/python-tss-sdk/issues/9, https://github.com/ansible-collections/community.general/pull/5151).
|
||||
|
||||
New Modules
|
||||
-----------
|
||||
|
||||
Packaging
|
||||
~~~~~~~~~
|
||||
|
||||
language
|
||||
^^^^^^^^
|
||||
|
||||
- pipx_info - Rretrieves information about applications installed with pipx
|
||||
|
||||
v5.5.0
|
||||
======
|
||||
|
||||
|
||||
@@ -1076,3 +1076,87 @@ releases:
|
||||
- licenses-2.yml
|
||||
- licenses.yml
|
||||
release_date: '2022-08-23'
|
||||
5.6.0:
|
||||
changes:
|
||||
bugfixes:
|
||||
- listen_ports_facts - removed leftover ``EnvironmentError`` . The ``else``
|
||||
clause had a wrong indentation. The check is now handled in the ``split_pid_name``
|
||||
function (https://github.com/ansible-collections/community.general/pull/5202).
|
||||
- nmcli - avoid changed status for most cases with VPN connections (https://github.com/ansible-collections/community.general/pull/5126).
|
||||
- osx_defaults - no longer expand ``~`` in ``value`` to the user's home directory,
|
||||
or expand environment variables (https://github.com/ansible-collections/community.general/issues/5234,
|
||||
https://github.com/ansible-collections/community.general/pull/5243).
|
||||
- proxmox_kvm - fix exception when no ``agent`` argument is specified (https://github.com/ansible-collections/community.general/pull/5194).
|
||||
- proxmox_kvm - replace new condition with proper condition to allow for using
|
||||
``vmid`` on update (https://github.com/ansible-collections/community.general/pull/5206).
|
||||
- slack - fix message update for channels which start with ``CP``. When ``message-id``
|
||||
was passed it failed for channels which started with ``CP`` because the ``#``
|
||||
symbol was added before the ``channel_id`` (https://github.com/ansible-collections/community.general/pull/5249).
|
||||
- tss lookup plugin - adding support for updated Delinea library (https://github.com/DelineaXPM/python-tss-sdk/issues/9,
|
||||
https://github.com/ansible-collections/community.general/pull/5151).
|
||||
deprecated_features:
|
||||
- proxmox - deprecated the current ``unprivileged`` default value, will be changed
|
||||
to ``true`` in community.general 7.0.0 (https://github.com/pull/5224).
|
||||
minor_changes:
|
||||
- ali_instance - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5240).
|
||||
- ali_instance_info - minor refactor when checking for installed dependency
|
||||
(https://github.com/ansible-collections/community.general/pull/5240).
|
||||
- consul_session - adds ``token`` parameter for session (https://github.com/ansible-collections/community.general/pull/5193).
|
||||
- gitlab module util - minor refactor when checking for installed dependency
|
||||
(https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_branch - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_deploy_key - minor refactor when checking for installed dependency
|
||||
(https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_group - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_group_members - minor refactor when checking for installed dependency
|
||||
(https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_group_variable - minor refactor when checking for installed dependency
|
||||
(https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_hook - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_hook - minor refactoring (https://github.com/ansible-collections/community.general/pull/5271).
|
||||
- gitlab_project - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_project_members - minor refactor when checking for installed dependency
|
||||
(https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_project_variable - minor refactor when checking for installed dependency
|
||||
(https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_protected_branch - minor refactor when checking for installed dependency
|
||||
(https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_runner - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- gitlab_user - minor refactor when checking for installed dependency (https://github.com/ansible-collections/community.general/pull/5259).
|
||||
- homebrew, homebrew_tap - added Homebrew on Linux path to defaults (https://github.com/ansible-collections/community.general/pull/5241).
|
||||
- nagios - minor refactoring on parameter validation for different actions (https://github.com/ansible-collections/community.general/pull/5239).
|
||||
- nmcli - add bond option ``xmit_hash_policy`` to bond options (https://github.com/ansible-collections/community.general/issues/5148).
|
||||
- nmcli - honor IP options for VPNs (https://github.com/ansible-collections/community.general/pull/5228).
|
||||
- redfish - added new command GetVirtualMedia, VirtualMediaInsert and VirtualMediaEject
|
||||
to Systems category due to Redfish spec changes the virtualMedia resource
|
||||
location from Manager to System (https://github.com/ansible-collections/community.general/pull/5124).
|
||||
- seport - added new argument ``local`` (https://github.com/ansible-collections/community.general/pull/5203)
|
||||
- wdc_redfish_command - add ``PowerModeLow`` and ``PowerModeNormal`` commands
|
||||
for ``Chassis`` category (https://github.com/ansible-collections/community.general/pull/5145).
|
||||
release_summary: Regular bugfix and feature release.
|
||||
fragments:
|
||||
- 5.6.0.yml
|
||||
- 5124-compatibility-virtualmedia-resource-location.yaml
|
||||
- 5126-nmcli-remove-diffs.yml
|
||||
- 5145-wdc-redfish-enclosure-power-state.yml
|
||||
- 5149-nmcli-bond-option.yml
|
||||
- 5151-add-delinea-support-tss-lookup.yml
|
||||
- 5193-consul-session-token.yaml
|
||||
- 5194-fix-proxmox-agent-exception.yaml
|
||||
- 5202-bugfix-environmentError-wrong-indentation.yaml
|
||||
- 5203-seport-add-local-argument.yaml
|
||||
- 5206-proxmox-conditional-vmid.yml
|
||||
- 5224-proxmox-unprivileged-default.yaml
|
||||
- 5228-nmcli-ip-options.yaml
|
||||
- 5239-nagios-refactor.yaml
|
||||
- 5240-unused-imports.yaml
|
||||
- 5241-homebrew-add-linux-path.yaml
|
||||
- 5243-osx-defaults-expand-user-flags.yml
|
||||
- 5249-add-new-channel-prefix.yml
|
||||
- 5259-gitlab-imports.yaml
|
||||
- 5271-gitlab_hook-refactor.yaml
|
||||
modules:
|
||||
- description: Rretrieves information about applications installed with pipx
|
||||
name: pipx_info
|
||||
namespace: packaging.language
|
||||
release_date: '2022-09-13'
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
namespace: community
|
||||
name: general
|
||||
version: 5.5.0
|
||||
version: 5.6.0
|
||||
readme: README.md
|
||||
authors:
|
||||
- Ansible (https://github.com/ansible)
|
||||
|
||||
@@ -1131,6 +1131,8 @@ plugin_routing:
|
||||
redirect: community.general.packaging.language.pip_package_info
|
||||
pipx:
|
||||
redirect: community.general.packaging.language.pipx
|
||||
pipx_info:
|
||||
redirect: community.general.packaging.language.pipx_info
|
||||
pkg5:
|
||||
redirect: community.general.packaging.os.pkg5
|
||||
pkg5_publisher:
|
||||
|
||||
@@ -55,7 +55,7 @@ DOCUMENTATION = '''
|
||||
- name: ANSIBLE_DOAS_FLAGS
|
||||
become_pass:
|
||||
description: password for doas prompt
|
||||
required: False
|
||||
required: false
|
||||
vars:
|
||||
- name: ansible_become_password
|
||||
- name: ansible_become_pass
|
||||
|
||||
@@ -55,7 +55,7 @@ DOCUMENTATION = '''
|
||||
- name: ANSIBLE_DZDO_FLAGS
|
||||
become_pass:
|
||||
description: Options to pass to dzdo
|
||||
required: False
|
||||
required: false
|
||||
vars:
|
||||
- name: ansible_become_password
|
||||
- name: ansible_become_pass
|
||||
|
||||
@@ -25,7 +25,7 @@ DOCUMENTATION = '''
|
||||
env:
|
||||
- name: ANSIBLE_BECOME_USER
|
||||
- name: ANSIBLE_KSU_USER
|
||||
required: True
|
||||
required: true
|
||||
become_exe:
|
||||
description: Su executable
|
||||
default: ksu
|
||||
@@ -56,7 +56,7 @@ DOCUMENTATION = '''
|
||||
- name: ANSIBLE_KSU_FLAGS
|
||||
become_pass:
|
||||
description: ksu password
|
||||
required: False
|
||||
required: false
|
||||
vars:
|
||||
- name: ansible_ksu_pass
|
||||
- name: ansible_become_pass
|
||||
|
||||
@@ -56,7 +56,7 @@ DOCUMENTATION = '''
|
||||
- name: ANSIBLE_MACHINECTL_FLAGS
|
||||
become_pass:
|
||||
description: Password for machinectl
|
||||
required: False
|
||||
required: false
|
||||
vars:
|
||||
- name: ansible_become_password
|
||||
- name: ansible_become_pass
|
||||
|
||||
@@ -56,7 +56,7 @@ DOCUMENTATION = '''
|
||||
- name: ANSIBLE_PBRUN_FLAGS
|
||||
become_pass:
|
||||
description: Password for pbrun
|
||||
required: False
|
||||
required: false
|
||||
vars:
|
||||
- name: ansible_become_password
|
||||
- name: ansible_become_pass
|
||||
@@ -69,7 +69,7 @@ DOCUMENTATION = '''
|
||||
key: password
|
||||
wrap_exe:
|
||||
description: Toggle to wrap the command pbrun calls in 'shell -c' or not
|
||||
default: False
|
||||
default: false
|
||||
type: bool
|
||||
ini:
|
||||
- section: pbrun_become_plugin
|
||||
|
||||
@@ -59,7 +59,7 @@ DOCUMENTATION = '''
|
||||
- name: ANSIBLE_PFEXEC_FLAGS
|
||||
become_pass:
|
||||
description: pfexec password
|
||||
required: False
|
||||
required: false
|
||||
vars:
|
||||
- name: ansible_become_password
|
||||
- name: ansible_become_pass
|
||||
@@ -72,7 +72,7 @@ DOCUMENTATION = '''
|
||||
key: password
|
||||
wrap_exe:
|
||||
description: Toggle to wrap the command pfexec calls in 'shell -c' or not
|
||||
default: False
|
||||
default: false
|
||||
type: bool
|
||||
ini:
|
||||
- section: pfexec_become_plugin
|
||||
|
||||
@@ -42,7 +42,7 @@ DOCUMENTATION = '''
|
||||
- name: ANSIBLE_PMRUN_FLAGS
|
||||
become_pass:
|
||||
description: pmrun password
|
||||
required: False
|
||||
required: false
|
||||
vars:
|
||||
- name: ansible_become_password
|
||||
- name: ansible_become_pass
|
||||
|
||||
@@ -56,7 +56,7 @@ DOCUMENTATION = '''
|
||||
- name: ANSIBLE_SESU_FLAGS
|
||||
become_pass:
|
||||
description: Password to pass to sesu
|
||||
required: False
|
||||
required: false
|
||||
vars:
|
||||
- name: ansible_become_password
|
||||
- name: ansible_become_pass
|
||||
|
||||
2
plugins/cache/pickle.py
vendored
2
plugins/cache/pickle.py
vendored
@@ -16,7 +16,7 @@ DOCUMENTATION = '''
|
||||
author: Brian Coca (@bcoca)
|
||||
options:
|
||||
_uri:
|
||||
required: True
|
||||
required: true
|
||||
description:
|
||||
- Path in which the cache plugin will save the files
|
||||
env:
|
||||
|
||||
2
plugins/cache/redis.py
vendored
2
plugins/cache/redis.py
vendored
@@ -21,7 +21,7 @@ DOCUMENTATION = '''
|
||||
- The format is C(host:port:db:password), for example C(localhost:6379:0:changeme).
|
||||
- To use encryption in transit, prefix the connection with C(tls://), as in C(tls://localhost:6379:0:changeme).
|
||||
- To use redis sentinel, use separator C(;), for example C(localhost:26379;localhost:26379;0:changeme). Requires redis>=2.9.0.
|
||||
required: True
|
||||
required: true
|
||||
env:
|
||||
- name: ANSIBLE_CACHE_PLUGIN_CONNECTION
|
||||
ini:
|
||||
|
||||
2
plugins/cache/yaml.py
vendored
2
plugins/cache/yaml.py
vendored
@@ -16,7 +16,7 @@ DOCUMENTATION = '''
|
||||
author: Brian Coca (@bcoca)
|
||||
options:
|
||||
_uri:
|
||||
required: True
|
||||
required: true
|
||||
description:
|
||||
- Path in which the cache plugin will save the files
|
||||
env:
|
||||
|
||||
@@ -23,7 +23,7 @@ DOCUMENTATION = '''
|
||||
- To create the cgroup, first use a command such as C(sudo cgcreate -a ec2-user:ec2-user -t ec2-user:ec2-user -g memory:ansible_profile)
|
||||
options:
|
||||
max_mem_file:
|
||||
required: True
|
||||
required: true
|
||||
description: Path to cgroups C(memory.max_usage_in_bytes) file. Example C(/sys/fs/cgroup/memory/ansible_profile/memory.max_usage_in_bytes)
|
||||
env:
|
||||
- name: CGROUP_MAX_MEM_FILE
|
||||
@@ -31,7 +31,7 @@ DOCUMENTATION = '''
|
||||
- section: callback_cgroupmemrecap
|
||||
key: max_mem_file
|
||||
cur_mem_file:
|
||||
required: True
|
||||
required: true
|
||||
description: Path to C(memory.usage_in_bytes) file. Example C(/sys/fs/cgroup/memory/ansible_profile/memory.usage_in_bytes)
|
||||
env:
|
||||
- name: CGROUP_CUR_MEM_FILE
|
||||
|
||||
@@ -627,7 +627,7 @@ playbook.yml: >
|
||||
---
|
||||
- name: "Default plugin output: play example"
|
||||
hosts: localhost
|
||||
gather_facts: no
|
||||
gather_facts: false
|
||||
tasks:
|
||||
- name: Default plugin output
|
||||
ansible.builtin.debug:
|
||||
@@ -635,7 +635,7 @@ playbook.yml: >
|
||||
|
||||
- name: Override from play vars
|
||||
hosts: localhost
|
||||
gather_facts: no
|
||||
gather_facts: false
|
||||
vars:
|
||||
ansible_connection: local
|
||||
green: "\e[0m\e[38;5;82m"
|
||||
@@ -713,7 +713,7 @@ playbook.yml: >
|
||||
- name: Using alias vars (see ansible.cfg)
|
||||
ansible.builtin.debug:
|
||||
msg:
|
||||
when: False
|
||||
when: false
|
||||
vars:
|
||||
ansible_callback_diy_playbook_on_task_start_msg: ""
|
||||
on_skipped_msg: "DIY output(via task vars): skipped example:\n\e[0m\e[38;5;4m\u25b6\u25b6 {{ ansible_callback_diy.result.task.name }}\n"
|
||||
|
||||
@@ -21,7 +21,7 @@ DOCUMENTATION = '''
|
||||
options:
|
||||
token:
|
||||
description: HipChat API token for v1 or v2 API.
|
||||
required: True
|
||||
required: true
|
||||
env:
|
||||
- name: HIPCHAT_TOKEN
|
||||
ini:
|
||||
@@ -29,7 +29,7 @@ DOCUMENTATION = '''
|
||||
key: token
|
||||
api_version:
|
||||
description: HipChat API version, v1 or v2.
|
||||
required: False
|
||||
required: false
|
||||
default: v1
|
||||
env:
|
||||
- name: HIPCHAT_API_VERSION
|
||||
@@ -55,7 +55,7 @@ DOCUMENTATION = '''
|
||||
notify:
|
||||
description: Add notify flag to important messages
|
||||
type: bool
|
||||
default: True
|
||||
default: true
|
||||
env:
|
||||
- name: HIPCHAT_NOTIFY
|
||||
ini:
|
||||
|
||||
@@ -20,22 +20,22 @@ DOCUMENTATION = '''
|
||||
options:
|
||||
server:
|
||||
description: connection info to jabber server
|
||||
required: True
|
||||
required: true
|
||||
env:
|
||||
- name: JABBER_SERV
|
||||
user:
|
||||
description: Jabber user to authenticate as
|
||||
required: True
|
||||
required: true
|
||||
env:
|
||||
- name: JABBER_USER
|
||||
password:
|
||||
description: Password for the user to the jabber server
|
||||
required: True
|
||||
required: true
|
||||
env:
|
||||
- name: JABBER_PASS
|
||||
to:
|
||||
description: chat identifier that will receive the message
|
||||
required: True
|
||||
required: true
|
||||
env:
|
||||
- name: JABBER_TO
|
||||
'''
|
||||
|
||||
@@ -18,7 +18,7 @@ DOCUMENTATION = '''
|
||||
- whitelisting in configuration
|
||||
options:
|
||||
conf_key:
|
||||
required: True
|
||||
required: true
|
||||
description: LogDNA Ingestion Key
|
||||
type: string
|
||||
env:
|
||||
@@ -27,7 +27,7 @@ DOCUMENTATION = '''
|
||||
- section: callback_logdna
|
||||
key: conf_key
|
||||
plugin_ignore_errors:
|
||||
required: False
|
||||
required: false
|
||||
description: Whether to ignore errors on failing or not
|
||||
type: boolean
|
||||
env:
|
||||
@@ -35,9 +35,9 @@ DOCUMENTATION = '''
|
||||
ini:
|
||||
- section: callback_logdna
|
||||
key: plugin_ignore_errors
|
||||
default: False
|
||||
default: false
|
||||
conf_hostname:
|
||||
required: False
|
||||
required: false
|
||||
description: Alternative Host Name; the current host name by default
|
||||
type: string
|
||||
env:
|
||||
@@ -46,7 +46,7 @@ DOCUMENTATION = '''
|
||||
- section: callback_logdna
|
||||
key: conf_hostname
|
||||
conf_tags:
|
||||
required: False
|
||||
required: false
|
||||
description: Tags
|
||||
type: string
|
||||
env:
|
||||
|
||||
@@ -48,7 +48,7 @@ DOCUMENTATION = '''
|
||||
description: The logentries "TCP token"
|
||||
env:
|
||||
- name: LOGENTRIES_ANSIBLE_TOKEN
|
||||
required: True
|
||||
required: true
|
||||
ini:
|
||||
- section: callback_logentries
|
||||
key: token
|
||||
@@ -57,7 +57,7 @@ DOCUMENTATION = '''
|
||||
- Toggle to decide whether to use TLS to encrypt the communications with the API server
|
||||
env:
|
||||
- name: LOGENTRIES_USE_TLS
|
||||
default: False
|
||||
default: false
|
||||
type: boolean
|
||||
ini:
|
||||
- section: callback_logentries
|
||||
@@ -65,7 +65,7 @@ DOCUMENTATION = '''
|
||||
flatten:
|
||||
description: flatten complex data structures into a single dictionary with complex keys
|
||||
type: boolean
|
||||
default: False
|
||||
default: false
|
||||
env:
|
||||
- name: LOGENTRIES_FLATTEN
|
||||
ini:
|
||||
|
||||
@@ -21,7 +21,7 @@ DOCUMENTATION = '''
|
||||
- If you increase verbosity all tasks are printed.
|
||||
options:
|
||||
nocolor:
|
||||
default: False
|
||||
default: false
|
||||
description: This setting allows suppressing colorizing output
|
||||
env:
|
||||
- name: ANSIBLE_NOCOLOR
|
||||
|
||||
@@ -21,7 +21,7 @@ DOCUMENTATION = '''
|
||||
- Before 2.4 only environment variables were available for configuring this plugin
|
||||
options:
|
||||
webhook_url:
|
||||
required: True
|
||||
required: true
|
||||
description: Slack Webhook URL
|
||||
env:
|
||||
- name: SLACK_WEBHOOK_URL
|
||||
@@ -51,7 +51,7 @@ DOCUMENTATION = '''
|
||||
ini:
|
||||
- section: callback_slack
|
||||
key: validate_certs
|
||||
default: True
|
||||
default: true
|
||||
type: bool
|
||||
'''
|
||||
|
||||
|
||||
@@ -28,5 +28,5 @@ options:
|
||||
description:
|
||||
- Whether or not to validate SSL certs when supplying a https endpoint.
|
||||
type: bool
|
||||
default: yes
|
||||
default: true
|
||||
'''
|
||||
|
||||
@@ -47,5 +47,5 @@ options:
|
||||
- If C(false), SSL certificates will not be validated.
|
||||
- This should only be used on private instances of the CloudControl API that use self-signed certificates.
|
||||
type: bool
|
||||
default: yes
|
||||
default: true
|
||||
'''
|
||||
|
||||
@@ -21,7 +21,7 @@ options:
|
||||
description:
|
||||
- Should we wait for the task to complete before moving onto the next.
|
||||
type: bool
|
||||
default: no
|
||||
default: false
|
||||
wait_time:
|
||||
description:
|
||||
- The maximum amount of time (in seconds) to wait for the task to complete.
|
||||
|
||||
@@ -18,17 +18,17 @@ options:
|
||||
description:
|
||||
- Management user on the spectrum accelerate storage system.
|
||||
type: str
|
||||
required: True
|
||||
required: true
|
||||
password:
|
||||
description:
|
||||
- Password for username on the spectrum accelerate storage system.
|
||||
type: str
|
||||
required: True
|
||||
required: true
|
||||
endpoints:
|
||||
description:
|
||||
- The hostname or management IP of Spectrum Accelerate storage system.
|
||||
type: str
|
||||
required: True
|
||||
required: true
|
||||
notes:
|
||||
- This module requires pyxcli python library.
|
||||
Use 'pip install pyxcli' in order to get pyxcli.
|
||||
|
||||
@@ -46,10 +46,10 @@ options:
|
||||
version_added: '0.2.0'
|
||||
validate_certs:
|
||||
description:
|
||||
- If set to C(no), the SSL certificates will not be validated.
|
||||
- This should only set to C(no) used on personally controlled sites using self-signed certificates.
|
||||
- If set to C(false), the SSL certificates will not be validated.
|
||||
- This should only set to C(false) used on personally controlled sites using self-signed certificates.
|
||||
type: bool
|
||||
default: yes
|
||||
default: true
|
||||
ssl:
|
||||
description:
|
||||
- Use https instead of http to connect to InfluxDB server.
|
||||
|
||||
@@ -61,10 +61,10 @@ options:
|
||||
validate_certs:
|
||||
description:
|
||||
- This only applies if C(ipa_prot) is I(https).
|
||||
- If set to C(no), the SSL certificates will not be validated.
|
||||
- This should only set to C(no) used on personally controlled sites using self-signed certificates.
|
||||
- If set to C(false), the SSL certificates will not be validated.
|
||||
- This should only set to C(false) used on personally controlled sites using self-signed certificates.
|
||||
type: bool
|
||||
default: yes
|
||||
default: true
|
||||
ipa_timeout:
|
||||
description:
|
||||
- Specifies idle timeout (in seconds) for the connection.
|
||||
|
||||
@@ -61,7 +61,7 @@ options:
|
||||
description:
|
||||
- Verify TLS certificates (do not disable this in production).
|
||||
type: bool
|
||||
default: yes
|
||||
default: true
|
||||
|
||||
connection_timeout:
|
||||
description:
|
||||
|
||||
@@ -49,13 +49,13 @@ options:
|
||||
description:
|
||||
- If true, we'll use the START_TLS LDAP extension.
|
||||
type: bool
|
||||
default: no
|
||||
default: false
|
||||
validate_certs:
|
||||
description:
|
||||
- If set to C(no), SSL certificates will not be validated.
|
||||
- If set to C(false), SSL certificates will not be validated.
|
||||
- This should only be used on sites using self-signed certificates.
|
||||
type: bool
|
||||
default: yes
|
||||
default: true
|
||||
sasl_class:
|
||||
description:
|
||||
- The class to use for SASL authentication.
|
||||
|
||||
@@ -40,7 +40,7 @@ options:
|
||||
description:
|
||||
- Whether SSL certificates should be verified for HTTPS requests. defaults to True.
|
||||
type: bool
|
||||
default: yes
|
||||
default: true
|
||||
aliases: [ verify_ssl ]
|
||||
ca_cert:
|
||||
description:
|
||||
|
||||
@@ -63,7 +63,7 @@ options:
|
||||
- When the ETag Validation is enabled, the request will be conditionally processed only if the current ETag
|
||||
for the resource matches the ETag provided in the data.
|
||||
type: bool
|
||||
default: yes
|
||||
default: true
|
||||
'''
|
||||
|
||||
FACTSPARAMS = r'''
|
||||
|
||||
@@ -34,7 +34,7 @@ options:
|
||||
description:
|
||||
- Validate SSL certs of the Online API.
|
||||
type: bool
|
||||
default: yes
|
||||
default: true
|
||||
notes:
|
||||
- Also see the API documentation on U(https://console.online.net/en/api/)
|
||||
- If C(api_token) is not set within the module, the following
|
||||
|
||||
@@ -36,7 +36,7 @@ options:
|
||||
- Whether to validate the SSL certificates or not.
|
||||
- This parameter is ignored if PYTHONHTTPSVERIFY environment variable is used.
|
||||
type: bool
|
||||
default: yes
|
||||
default: true
|
||||
wait_timeout:
|
||||
description:
|
||||
- Time to wait for the desired state to be reached before timeout, in seconds.
|
||||
|
||||
@@ -71,11 +71,11 @@ options:
|
||||
default: ssh
|
||||
use_ssl:
|
||||
description:
|
||||
- Configures the I(transport) to use SSL if set to C(yes) only when the
|
||||
- Configures the I(transport) to use SSL if set to C(true) only when the
|
||||
I(transport) argument is configured as rest. If the transport
|
||||
argument is not I(rest), this value is ignored.
|
||||
type: bool
|
||||
default: yes
|
||||
default: true
|
||||
provider:
|
||||
description:
|
||||
- Convenience method that allows all I(openswitch) arguments to be passed as
|
||||
|
||||
@@ -15,7 +15,7 @@ class ModuleDocFragment(object):
|
||||
idempotent operation, and doesn't create the resource if it already exists. Setting this option
|
||||
to true, forcefully creates a copy of the resource, even if it already exists.This option is
|
||||
mutually exclusive with I(key_by).
|
||||
default: False
|
||||
default: false
|
||||
type: bool
|
||||
key_by:
|
||||
description: The list of comma-separated attributes of this resource which should be used to uniquely
|
||||
|
||||
@@ -12,15 +12,15 @@ class ModuleDocFragment(object):
|
||||
options:
|
||||
wait:
|
||||
description: Whether to wait for create or delete operation to complete.
|
||||
default: yes
|
||||
default: true
|
||||
type: bool
|
||||
wait_timeout:
|
||||
description: Time, in seconds, to wait when I(wait=yes).
|
||||
description: Time, in seconds, to wait when I(wait=true).
|
||||
default: 1200
|
||||
type: int
|
||||
wait_until:
|
||||
description: The lifecycle state to wait for the resource to transition into when I(wait=yes). By default,
|
||||
when I(wait=yes), we wait for the resource to get into ACTIVE/ATTACHED/AVAILABLE/PROVISIONED/
|
||||
description: The lifecycle state to wait for the resource to transition into when I(wait=true). By default,
|
||||
when I(wait=true), we wait for the resource to get into ACTIVE/ATTACHED/AVAILABLE/PROVISIONED/
|
||||
RUNNING applicable lifecycle state during create operation & to get into DELETED/DETACHED/
|
||||
TERMINATED lifecycle state during delete operation.
|
||||
type: str
|
||||
|
||||
@@ -38,10 +38,10 @@ options:
|
||||
version_added: 1.3.0
|
||||
validate_certs:
|
||||
description:
|
||||
- If C(no), SSL certificates will not be validated.
|
||||
- If C(false), SSL certificates will not be validated.
|
||||
- This should only be used on personally controlled sites using self-signed certificates.
|
||||
type: bool
|
||||
default: no
|
||||
default: false
|
||||
requirements: [ "proxmoxer", "requests" ]
|
||||
'''
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@ options:
|
||||
description:
|
||||
- Validate SSL certs of the Scaleway API.
|
||||
type: bool
|
||||
default: yes
|
||||
default: true
|
||||
notes:
|
||||
- Also see the API documentation on U(https://developer.scaleway.com/)
|
||||
- If C(api_token) is not set within the module, the following
|
||||
|
||||
@@ -43,7 +43,7 @@ options:
|
||||
description:
|
||||
- Whether the REST interface's ssl certificate should be verified or not.
|
||||
type: bool
|
||||
default: yes
|
||||
default: true
|
||||
state:
|
||||
description:
|
||||
- The desired state of the object.
|
||||
|
||||
@@ -40,10 +40,10 @@ options:
|
||||
validate_certs:
|
||||
description:
|
||||
- Allows connection when SSL certificates are not valid. Set to C(false) when certificates are not trusted.
|
||||
- If set to C(yes), please make sure Python >= 2.7.9 is installed on the given machine.
|
||||
- If set to C(true), please make sure Python >= 2.7.9 is installed on the given machine.
|
||||
required: false
|
||||
type: bool
|
||||
default: 'no'
|
||||
default: false
|
||||
|
||||
requirements:
|
||||
- Vexata VX100 storage array with VXOS >= v3.5.0 on storage array
|
||||
|
||||
@@ -37,5 +37,5 @@ options:
|
||||
- Allows connection when SSL certificates are not valid. Set to C(false) when certificates are not trusted.
|
||||
- If the value is not specified in the task, the value of environment variable C(XENSERVER_VALIDATE_CERTS) will be used instead.
|
||||
type: bool
|
||||
default: yes
|
||||
default: true
|
||||
'''
|
||||
|
||||
@@ -19,7 +19,7 @@ DOCUMENTATION = '''
|
||||
options:
|
||||
plugin:
|
||||
description: The name of this plugin, it should always be set to C(community.general.cobbler) for this plugin to recognize it as it's own.
|
||||
required: yes
|
||||
required: true
|
||||
choices: [ 'cobbler', 'community.general.cobbler' ]
|
||||
url:
|
||||
description: URL to cobbler.
|
||||
@@ -28,18 +28,18 @@ DOCUMENTATION = '''
|
||||
- name: COBBLER_SERVER
|
||||
user:
|
||||
description: Cobbler authentication user.
|
||||
required: no
|
||||
required: false
|
||||
env:
|
||||
- name: COBBLER_USER
|
||||
password:
|
||||
description: Cobbler authentication password
|
||||
required: no
|
||||
required: false
|
||||
env:
|
||||
- name: COBBLER_PASSWORD
|
||||
cache_fallback:
|
||||
description: Fallback to cached results if connection to cobbler fails
|
||||
type: boolean
|
||||
default: no
|
||||
default: false
|
||||
exclude_profiles:
|
||||
description:
|
||||
- Profiles to exclude from inventory.
|
||||
@@ -70,7 +70,7 @@ DOCUMENTATION = '''
|
||||
want_facts:
|
||||
description: Toggle, if C(true) the plugin will retrieve host facts from the server
|
||||
type: boolean
|
||||
default: yes
|
||||
default: true
|
||||
'''
|
||||
|
||||
EXAMPLES = '''
|
||||
|
||||
@@ -55,7 +55,7 @@ DOCUMENTATION = '''
|
||||
verbose_output:
|
||||
description: Toggle to (not) include all available nodes metadata
|
||||
type: bool
|
||||
default: yes
|
||||
default: true
|
||||
'''
|
||||
|
||||
EXAMPLES = '''
|
||||
@@ -66,7 +66,7 @@ host: https://gitlab.com
|
||||
# Example using constructed features to create groups and set ansible_host
|
||||
plugin: community.general.gitlab_runners
|
||||
host: https://gitlab.com
|
||||
strict: False
|
||||
strict: false
|
||||
keyed_groups:
|
||||
# add e.g. amd64 hosts to an arch_amd64 group
|
||||
- prefix: arch
|
||||
|
||||
@@ -20,7 +20,7 @@ DOCUMENTATION = '''
|
||||
options:
|
||||
plugin:
|
||||
description: token that ensures this is a source file for the 'nmap' plugin.
|
||||
required: True
|
||||
required: true
|
||||
choices: ['nmap', 'community.general.nmap']
|
||||
sudo:
|
||||
description: Set to C(true) to execute a C(sudo nmap) plugin scan.
|
||||
@@ -29,7 +29,7 @@ DOCUMENTATION = '''
|
||||
type: boolean
|
||||
address:
|
||||
description: Network IP or range of IPs to scan, you can use a simple range (10.2.2.15-25) or CIDR notation.
|
||||
required: True
|
||||
required: true
|
||||
exclude:
|
||||
description: list of addresses to exclude
|
||||
type: list
|
||||
@@ -37,15 +37,15 @@ DOCUMENTATION = '''
|
||||
ports:
|
||||
description: Enable/disable scanning for open ports
|
||||
type: boolean
|
||||
default: True
|
||||
default: true
|
||||
ipv4:
|
||||
description: use IPv4 type addresses
|
||||
type: boolean
|
||||
default: True
|
||||
default: true
|
||||
ipv6:
|
||||
description: use IPv6 type addresses
|
||||
type: boolean
|
||||
default: True
|
||||
default: true
|
||||
notes:
|
||||
- At least one of ipv4 or ipv6 is required to be True, both can be True, but they cannot both be False.
|
||||
- 'TODO: add OS fingerprinting'
|
||||
@@ -53,14 +53,14 @@ DOCUMENTATION = '''
|
||||
EXAMPLES = '''
|
||||
# inventory.config file in YAML format
|
||||
plugin: community.general.nmap
|
||||
strict: False
|
||||
strict: false
|
||||
address: 192.168.0.0/24
|
||||
|
||||
|
||||
# a sudo nmap scan to fully use nmap scan power.
|
||||
plugin: community.general.nmap
|
||||
sudo: true
|
||||
strict: False
|
||||
strict: false
|
||||
address: 192.168.0.0/24
|
||||
'''
|
||||
|
||||
|
||||
@@ -16,10 +16,10 @@ DOCUMENTATION = r'''
|
||||
options:
|
||||
plugin:
|
||||
description: token that ensures this is a source file for the 'online' plugin.
|
||||
required: True
|
||||
required: true
|
||||
choices: ['online', 'community.general.online']
|
||||
oauth_token:
|
||||
required: True
|
||||
required: true
|
||||
description: Online OAuth token.
|
||||
env:
|
||||
# in order of precedence
|
||||
|
||||
@@ -34,7 +34,7 @@ DOCUMENTATION = r'''
|
||||
- If not set then the value of the C(ONE_URL) environment variable is used.
|
||||
env:
|
||||
- name: ONE_URL
|
||||
required: True
|
||||
required: true
|
||||
type: string
|
||||
api_username:
|
||||
description:
|
||||
@@ -49,7 +49,7 @@ DOCUMENTATION = r'''
|
||||
- If not set, the value of the C(ONE_PASSWORD) environment variable is used.
|
||||
env:
|
||||
- name: ONE_PASSWORD
|
||||
required: False
|
||||
required: false
|
||||
type: string
|
||||
api_authfile:
|
||||
description:
|
||||
@@ -58,7 +58,7 @@ DOCUMENTATION = r'''
|
||||
- Set environment variable C(ONE_AUTH) to override this path.
|
||||
env:
|
||||
- name: ONE_AUTH
|
||||
required: False
|
||||
required: false
|
||||
type: string
|
||||
hostname:
|
||||
description: Field to match the hostname. Note C(v4_first_ip) corresponds to the first IPv4 found on VM.
|
||||
@@ -74,7 +74,7 @@ DOCUMENTATION = r'''
|
||||
group_by_labels:
|
||||
description: Create host groups by vm labels
|
||||
type: bool
|
||||
default: True
|
||||
default: true
|
||||
'''
|
||||
|
||||
EXAMPLES = r'''
|
||||
|
||||
@@ -26,7 +26,7 @@ DOCUMENTATION = '''
|
||||
options:
|
||||
plugin:
|
||||
description: The name of this plugin, it should always be set to C(community.general.proxmox) for this plugin to recognize it as it's own.
|
||||
required: yes
|
||||
required: true
|
||||
choices: ['community.general.proxmox']
|
||||
type: str
|
||||
url:
|
||||
@@ -44,7 +44,7 @@ DOCUMENTATION = '''
|
||||
- Proxmox authentication user.
|
||||
- If the value is not specified in the inventory configuration, the value of environment variable C(PROXMOX_USER) will be used instead.
|
||||
- Since community.general 4.7.0 you can also use templating to specify the value of the I(user).
|
||||
required: yes
|
||||
required: true
|
||||
type: str
|
||||
env:
|
||||
- name: PROXMOX_USER
|
||||
@@ -83,7 +83,7 @@ DOCUMENTATION = '''
|
||||
validate_certs:
|
||||
description: Verify SSL certificate if using HTTPS.
|
||||
type: boolean
|
||||
default: yes
|
||||
default: true
|
||||
group_prefix:
|
||||
description: Prefix to apply to Proxmox groups.
|
||||
default: proxmox_
|
||||
@@ -98,14 +98,14 @@ DOCUMENTATION = '''
|
||||
- When I(want_facts) is set to C(true) more details about QEMU VM status are possible, besides the running and stopped states.
|
||||
Currently if the VM is running and it is suspended, the status will be running and the machine will be in C(running) group,
|
||||
but its actual state will be paused. See I(qemu_extended_statuses) for how to retrieve the real status.
|
||||
default: no
|
||||
default: false
|
||||
type: bool
|
||||
qemu_extended_statuses:
|
||||
description:
|
||||
- Requires I(want_facts) to be set to C(true) to function. This will allow you to differentiate betweend C(paused) and C(prelaunch)
|
||||
statuses of the QEMU VMs.
|
||||
- This introduces multiple groups [prefixed with I(group_prefix)] C(prelaunch) and C(paused).
|
||||
default: no
|
||||
default: false
|
||||
type: bool
|
||||
version_added: 5.1.0
|
||||
want_proxmox_nodes_ansible_host:
|
||||
|
||||
@@ -19,7 +19,7 @@ DOCUMENTATION = r'''
|
||||
options:
|
||||
plugin:
|
||||
description: Token that ensures this is a source file for the 'scaleway' plugin.
|
||||
required: True
|
||||
required: true
|
||||
choices: ['scaleway', 'community.general.scaleway']
|
||||
regions:
|
||||
description: Filter results on a specific Scaleway region.
|
||||
|
||||
@@ -20,12 +20,12 @@ DOCUMENTATION = '''
|
||||
options:
|
||||
plugin:
|
||||
description: token that ensures this is a source file for the 'virtualbox' plugin
|
||||
required: True
|
||||
required: true
|
||||
choices: ['virtualbox', 'community.general.virtualbox']
|
||||
running_only:
|
||||
description: toggles showing all vms vs only those currently running
|
||||
type: boolean
|
||||
default: False
|
||||
default: false
|
||||
settings_password_file:
|
||||
description: provide a file containing the settings password (equivalent to --settingspwfile)
|
||||
network_info_path:
|
||||
|
||||
@@ -24,7 +24,7 @@ DOCUMENTATION = '''
|
||||
options:
|
||||
plugin:
|
||||
description: The name of this plugin, it should always be set to C(community.general.xen_orchestra) for this plugin to recognize it as its own.
|
||||
required: yes
|
||||
required: true
|
||||
choices: ['community.general.xen_orchestra']
|
||||
type: str
|
||||
api_host:
|
||||
@@ -38,7 +38,7 @@ DOCUMENTATION = '''
|
||||
description:
|
||||
- Xen Orchestra user.
|
||||
- If the value is not specified in the inventory configuration, the value of environment variable C(ANSIBLE_XO_USER) will be used instead.
|
||||
required: yes
|
||||
required: true
|
||||
type: str
|
||||
env:
|
||||
- name: ANSIBLE_XO_USER
|
||||
@@ -46,7 +46,7 @@ DOCUMENTATION = '''
|
||||
description:
|
||||
- Xen Orchestra password.
|
||||
- If the value is not specified in the inventory configuration, the value of environment variable C(ANSIBLE_XO_PASSWORD) will be used instead.
|
||||
required: yes
|
||||
required: true
|
||||
type: str
|
||||
env:
|
||||
- name: ANSIBLE_XO_PASSWORD
|
||||
|
||||
@@ -18,7 +18,7 @@ DOCUMENTATION = '''
|
||||
_raw:
|
||||
description:
|
||||
- a set of lists
|
||||
required: True
|
||||
required: true
|
||||
'''
|
||||
|
||||
EXAMPLES = """
|
||||
|
||||
@@ -22,11 +22,11 @@ DOCUMENTATION = '''
|
||||
name:
|
||||
description:
|
||||
- Name of the databag
|
||||
required: True
|
||||
required: true
|
||||
item:
|
||||
description:
|
||||
- Item to fetch
|
||||
required: True
|
||||
required: true
|
||||
'''
|
||||
|
||||
EXAMPLES = """
|
||||
|
||||
@@ -25,7 +25,7 @@ DOCUMENTATION = '''
|
||||
recurse:
|
||||
type: boolean
|
||||
description: If true, will retrieve all the values that have the given key as prefix.
|
||||
default: False
|
||||
default: false
|
||||
index:
|
||||
description:
|
||||
- If the key has a value with the specified index then this is returned allowing access to historical values.
|
||||
@@ -56,7 +56,7 @@ DOCUMENTATION = '''
|
||||
- Whether to use http or https.
|
||||
- If you use C(ANSIBLE_CONSUL_URL) this value will be used from there.
|
||||
validate_certs:
|
||||
default: True
|
||||
default: true
|
||||
description: Whether to verify the ssl connection or not.
|
||||
env:
|
||||
- name: ANSIBLE_CONSUL_VALIDATE_CERTS
|
||||
|
||||
@@ -22,10 +22,10 @@ DOCUMENTATION = '''
|
||||
default: '/opt/CARKaim/sdk/clipasswordsdk'
|
||||
appid:
|
||||
description: Defines the unique ID of the application that is issuing the password request.
|
||||
required: True
|
||||
required: true
|
||||
query:
|
||||
description: Describes the filter criteria for the password retrieval.
|
||||
required: True
|
||||
required: true
|
||||
output:
|
||||
description:
|
||||
- Specifies the desired output fields separated by commas.
|
||||
|
||||
@@ -17,7 +17,7 @@ DOCUMENTATION = '''
|
||||
options:
|
||||
_terms:
|
||||
description: domain or list of domains to query TXT records from
|
||||
required: True
|
||||
required: true
|
||||
type: list
|
||||
elements: string
|
||||
'''
|
||||
|
||||
@@ -21,7 +21,7 @@ DOCUMENTATION = '''
|
||||
- the list of keys to lookup on the etcd server
|
||||
type: list
|
||||
elements: string
|
||||
required: True
|
||||
required: true
|
||||
url:
|
||||
description:
|
||||
- Environment variable with the url for the etcd server
|
||||
@@ -37,7 +37,7 @@ DOCUMENTATION = '''
|
||||
validate_certs:
|
||||
description:
|
||||
- toggle checking that the ssl certificates are valid, you normally only want to turn this off with self-signed certs.
|
||||
default: True
|
||||
default: true
|
||||
type: boolean
|
||||
'''
|
||||
|
||||
|
||||
@@ -24,12 +24,12 @@ DOCUMENTATION = '''
|
||||
- The list of keys (or key prefixes) to look up on the etcd3 server.
|
||||
type: list
|
||||
elements: str
|
||||
required: True
|
||||
required: true
|
||||
prefix:
|
||||
description:
|
||||
- Look for key or prefix key.
|
||||
type: bool
|
||||
default: False
|
||||
default: false
|
||||
endpoints:
|
||||
description:
|
||||
- Counterpart of C(ETCDCTL_ENDPOINTS) environment variable.
|
||||
|
||||
@@ -18,7 +18,7 @@ description:
|
||||
options:
|
||||
_terms:
|
||||
description: path(s) of files to read
|
||||
required: True
|
||||
required: true
|
||||
'''
|
||||
|
||||
EXAMPLES = r"""
|
||||
@@ -46,7 +46,7 @@ EXAMPLES = r"""
|
||||
dest: /web/{{ item.path }}
|
||||
state: link
|
||||
follow: false # avoid corrupting target files if the link already exists
|
||||
force: yes
|
||||
force: true
|
||||
mode: '{{ item.mode }}'
|
||||
with_community.general.filetree: web/
|
||||
when: item.state == 'link'
|
||||
|
||||
@@ -15,7 +15,7 @@ DOCUMENTATION = '''
|
||||
options:
|
||||
_terms:
|
||||
description: lists to flatten
|
||||
required: True
|
||||
required: true
|
||||
notes:
|
||||
- unlike 'items' which only flattens 1 level, this plugin will continue to flatten until it cannot find lists anymore.
|
||||
- aka highlander plugin, there can only be one (list).
|
||||
|
||||
@@ -21,7 +21,7 @@ DOCUMENTATION = '''
|
||||
- The list of keys to lookup on the Puppetmaster
|
||||
type: list
|
||||
elements: string
|
||||
required: True
|
||||
required: true
|
||||
_bin_file:
|
||||
description:
|
||||
- Binary file to execute Hiera
|
||||
|
||||
@@ -20,24 +20,24 @@ DOCUMENTATION = '''
|
||||
matched resources will be returned.
|
||||
type: list
|
||||
elements: string
|
||||
required: False
|
||||
required: false
|
||||
api_token:
|
||||
description:
|
||||
- manifold API token
|
||||
type: string
|
||||
required: True
|
||||
required: true
|
||||
env:
|
||||
- name: MANIFOLD_API_TOKEN
|
||||
project:
|
||||
description:
|
||||
- The project label you want to get the resource for.
|
||||
type: string
|
||||
required: False
|
||||
required: false
|
||||
team:
|
||||
description:
|
||||
- The team label you want to get the resource for.
|
||||
type: string
|
||||
required: False
|
||||
required: false
|
||||
'''
|
||||
|
||||
EXAMPLES = '''
|
||||
|
||||
@@ -22,7 +22,7 @@ DOCUMENTATION = '''
|
||||
options:
|
||||
_terms:
|
||||
description: identifier(s) (UUID, name, or subdomain; case-insensitive) of item(s) to retrieve.
|
||||
required: True
|
||||
required: true
|
||||
field:
|
||||
description: field to return from each matching item (case-insensitive).
|
||||
default: 'password'
|
||||
|
||||
@@ -22,7 +22,7 @@ DOCUMENTATION = '''
|
||||
options:
|
||||
_terms:
|
||||
description: identifier(s) (UUID, name, or domain; case-insensitive) of item(s) to retrieve.
|
||||
required: True
|
||||
required: true
|
||||
master_password:
|
||||
description: The password used to unlock the specified vault.
|
||||
aliases: ['vault_password']
|
||||
|
||||
@@ -20,7 +20,7 @@ DOCUMENTATION = '''
|
||||
options:
|
||||
_terms:
|
||||
description: query key.
|
||||
required: True
|
||||
required: true
|
||||
passwordstore:
|
||||
description:
|
||||
- Location of the password store.
|
||||
@@ -41,7 +41,7 @@ DOCUMENTATION = '''
|
||||
overwrite:
|
||||
description: Overwrite the password if it does already exist.
|
||||
type: bool
|
||||
default: 'no'
|
||||
default: false
|
||||
umask:
|
||||
description:
|
||||
- Sets the umask for the created .gpg files. The first octed must be greater than 3 (user readable).
|
||||
@@ -52,7 +52,7 @@ DOCUMENTATION = '''
|
||||
returnall:
|
||||
description: Return all the content of the password, not only the first line.
|
||||
type: bool
|
||||
default: 'no'
|
||||
default: false
|
||||
subkey:
|
||||
description: Return a specific subkey of the password. When set to C(password), always returns the first line.
|
||||
default: password
|
||||
@@ -63,13 +63,13 @@ DOCUMENTATION = '''
|
||||
type: integer
|
||||
default: 16
|
||||
backup:
|
||||
description: Used with C(overwrite=yes). Backup the previous password in a subkey.
|
||||
description: Used with C(overwrite=true). Backup the previous password in a subkey.
|
||||
type: bool
|
||||
default: 'no'
|
||||
default: false
|
||||
nosymbols:
|
||||
description: use alphanumeric characters.
|
||||
type: bool
|
||||
default: 'no'
|
||||
default: false
|
||||
missing:
|
||||
description:
|
||||
- List of preference about what to do if the password file is missing.
|
||||
|
||||
@@ -17,10 +17,10 @@ DOCUMENTATION = '''
|
||||
description: sets of key value pairs of parameters
|
||||
key:
|
||||
description: key to query
|
||||
required: True
|
||||
required: true
|
||||
file:
|
||||
description: path to shelve file
|
||||
required: True
|
||||
required: true
|
||||
'''
|
||||
|
||||
EXAMPLES = """
|
||||
|
||||
@@ -171,19 +171,29 @@ try:
|
||||
|
||||
HAS_TSS_SDK = True
|
||||
except ImportError:
|
||||
SecretServer = None
|
||||
SecretServerError = None
|
||||
HAS_TSS_SDK = False
|
||||
try:
|
||||
from delinea.secrets.server import SecretServer, SecretServerError
|
||||
|
||||
HAS_TSS_SDK = True
|
||||
except ImportError:
|
||||
SecretServer = None
|
||||
SecretServerError = None
|
||||
HAS_TSS_SDK = False
|
||||
|
||||
try:
|
||||
from thycotic.secrets.server import PasswordGrantAuthorizer, DomainPasswordGrantAuthorizer, AccessTokenAuthorizer
|
||||
|
||||
HAS_TSS_AUTHORIZER = True
|
||||
except ImportError:
|
||||
PasswordGrantAuthorizer = None
|
||||
DomainPasswordGrantAuthorizer = None
|
||||
AccessTokenAuthorizer = None
|
||||
HAS_TSS_AUTHORIZER = False
|
||||
try:
|
||||
from delinea.secrets.server import PasswordGrantAuthorizer, DomainPasswordGrantAuthorizer, AccessTokenAuthorizer
|
||||
|
||||
HAS_TSS_AUTHORIZER = True
|
||||
except ImportError:
|
||||
PasswordGrantAuthorizer = None
|
||||
DomainPasswordGrantAuthorizer = None
|
||||
AccessTokenAuthorizer = None
|
||||
HAS_TSS_AUTHORIZER = False
|
||||
|
||||
|
||||
display = Display()
|
||||
|
||||
@@ -15,6 +15,7 @@ __metaclass__ = type
|
||||
|
||||
import os
|
||||
import json
|
||||
import traceback
|
||||
from ansible.module_utils.basic import env_fallback
|
||||
|
||||
try:
|
||||
@@ -28,8 +29,11 @@ try:
|
||||
import footmark.dns
|
||||
import footmark.ram
|
||||
import footmark.market
|
||||
|
||||
FOOTMARK_IMP_ERR = None
|
||||
HAS_FOOTMARK = True
|
||||
except ImportError:
|
||||
FOOTMARK_IMP_ERR = traceback.format_exc()
|
||||
HAS_FOOTMARK = False
|
||||
|
||||
|
||||
|
||||
@@ -14,10 +14,9 @@ from ansible.module_utils.common.text.converters import to_native
|
||||
from ansible_collections.community.general.plugins.module_utils.version import LooseVersion
|
||||
|
||||
try:
|
||||
from urllib import quote_plus # Python 2.X
|
||||
from urlparse import urljoin
|
||||
except ImportError:
|
||||
from urllib.parse import quote_plus, urljoin # Python 3+
|
||||
from urllib.parse import urljoin # Python 3+
|
||||
|
||||
import traceback
|
||||
|
||||
@@ -27,6 +26,7 @@ try:
|
||||
import requests
|
||||
HAS_GITLAB_PACKAGE = True
|
||||
except Exception:
|
||||
gitlab = None
|
||||
GITLAB_IMP_ERR = traceback.format_exc()
|
||||
HAS_GITLAB_PACKAGE = False
|
||||
|
||||
@@ -64,6 +64,14 @@ def find_group(gitlab_instance, identifier):
|
||||
return project
|
||||
|
||||
|
||||
def ensure_gitlab_package(module):
|
||||
if not HAS_GITLAB_PACKAGE:
|
||||
module.fail_json(
|
||||
msg=missing_required_lib("python-gitlab", url='https://python-gitlab.readthedocs.io/en/stable/'),
|
||||
exception=GITLAB_IMP_ERR
|
||||
)
|
||||
|
||||
|
||||
def gitlab_authentication(module):
|
||||
gitlab_url = module.params['api_url']
|
||||
validate_certs = module.params['validate_certs']
|
||||
@@ -73,8 +81,7 @@ def gitlab_authentication(module):
|
||||
gitlab_oauth_token = module.params['api_oauth_token']
|
||||
gitlab_job_token = module.params['api_job_token']
|
||||
|
||||
if not HAS_GITLAB_PACKAGE:
|
||||
module.fail_json(msg=missing_required_lib("python-gitlab"), exception=GITLAB_IMP_ERR)
|
||||
ensure_gitlab_package(module)
|
||||
|
||||
try:
|
||||
# python-gitlab library remove support for username/password authentication since 1.13.0
|
||||
|
||||
@@ -202,6 +202,16 @@ class RedfishUtils(object):
|
||||
def _init_session(self):
|
||||
pass
|
||||
|
||||
def _get_vendor(self):
|
||||
response = self.get_request(self.root_uri + self.service_root)
|
||||
if response['ret'] is False:
|
||||
return {'ret': False, 'Vendor': ''}
|
||||
data = response['data']
|
||||
if 'Vendor' in data:
|
||||
return {'ret': True, 'Vendor': data["Vendor"]}
|
||||
else:
|
||||
return {'ret': True, 'Vendor': ''}
|
||||
|
||||
def _find_accountservice_resource(self):
|
||||
response = self.get_request(self.root_uri + self.service_root)
|
||||
if response['ret'] is False:
|
||||
@@ -2162,11 +2172,15 @@ class RedfishUtils(object):
|
||||
result["entries"] = virtualmedia_results
|
||||
return result
|
||||
|
||||
def get_multi_virtualmedia(self):
|
||||
def get_multi_virtualmedia(self, resource_type='Manager'):
|
||||
ret = True
|
||||
entries = []
|
||||
|
||||
resource_uris = self.manager_uris
|
||||
# Given resource_type, use the proper URI
|
||||
if resource_type == 'Systems':
|
||||
resource_uris = self.systems_uris
|
||||
elif resource_type == 'Manager':
|
||||
resource_uris = self.manager_uris
|
||||
|
||||
for resource_uri in resource_uris:
|
||||
virtualmedia = self.get_virtualmedia(resource_uri)
|
||||
@@ -2178,7 +2192,7 @@ class RedfishUtils(object):
|
||||
|
||||
@staticmethod
|
||||
def _find_empty_virt_media_slot(resources, media_types,
|
||||
media_match_strict=True):
|
||||
media_match_strict=True, vendor=''):
|
||||
for uri, data in resources.items():
|
||||
# check MediaTypes
|
||||
if 'MediaTypes' in data and media_types:
|
||||
@@ -2187,8 +2201,12 @@ class RedfishUtils(object):
|
||||
else:
|
||||
if media_match_strict:
|
||||
continue
|
||||
# if ejected, 'Inserted' should be False
|
||||
if (not data.get('Inserted', False)):
|
||||
# Base on current Lenovo server capability, filter out slot RDOC1/2 and Remote1/2/3/4 which are not supported to Insert/Eject.
|
||||
if vendor == 'Lenovo' and ('RDOC' in uri or 'Remote' in uri):
|
||||
continue
|
||||
# if ejected, 'Inserted' should be False and 'ImageName' cleared
|
||||
if (not data.get('Inserted', False) and
|
||||
not data.get('ImageName')):
|
||||
return uri, data
|
||||
return None, None
|
||||
|
||||
@@ -2262,7 +2280,7 @@ class RedfishUtils(object):
|
||||
return response
|
||||
return {'ret': True, 'changed': True, 'msg': "VirtualMedia inserted"}
|
||||
|
||||
def virtual_media_insert(self, options):
|
||||
def virtual_media_insert(self, options, resource_type='Manager'):
|
||||
param_map = {
|
||||
'Inserted': 'inserted',
|
||||
'WriteProtected': 'write_protected',
|
||||
@@ -2279,7 +2297,12 @@ class RedfishUtils(object):
|
||||
media_types = options.get('media_types')
|
||||
|
||||
# locate and read the VirtualMedia resources
|
||||
response = self.get_request(self.root_uri + self.manager_uri)
|
||||
# Given resource_type, use the proper URI
|
||||
if resource_type == 'Systems':
|
||||
resource_uri = self.systems_uri
|
||||
elif resource_type == 'Manager':
|
||||
resource_uri = self.manager_uri
|
||||
response = self.get_request(self.root_uri + resource_uri)
|
||||
if response['ret'] is False:
|
||||
return response
|
||||
data = response['data']
|
||||
@@ -2288,7 +2311,7 @@ class RedfishUtils(object):
|
||||
|
||||
# Some hardware (such as iLO 4) only supports the Image property on the PATCH operation
|
||||
# Inserted and WriteProtected are not writable
|
||||
if data["FirmwareVersion"].startswith("iLO 4"):
|
||||
if "FirmwareVersion" in data and data["FirmwareVersion"].startswith("iLO 4"):
|
||||
image_only = True
|
||||
|
||||
# Supermicro does also not support Inserted and WriteProtected
|
||||
@@ -2315,12 +2338,13 @@ class RedfishUtils(object):
|
||||
|
||||
# find an empty slot to insert the media
|
||||
# try first with strict media_type matching
|
||||
vendor = self._get_vendor()['Vendor']
|
||||
uri, data = self._find_empty_virt_media_slot(
|
||||
resources, media_types, media_match_strict=True)
|
||||
resources, media_types, media_match_strict=True, vendor=vendor)
|
||||
if not uri:
|
||||
# if not found, try without strict media_type matching
|
||||
uri, data = self._find_empty_virt_media_slot(
|
||||
resources, media_types, media_match_strict=False)
|
||||
resources, media_types, media_match_strict=False, vendor=vendor)
|
||||
if not uri:
|
||||
return {'ret': False,
|
||||
'msg': "Unable to find an available VirtualMedia resource "
|
||||
@@ -2378,14 +2402,19 @@ class RedfishUtils(object):
|
||||
return {'ret': True, 'changed': True,
|
||||
'msg': "VirtualMedia ejected"}
|
||||
|
||||
def virtual_media_eject(self, options):
|
||||
def virtual_media_eject(self, options, resource_type='Manager'):
|
||||
image_url = options.get('image_url')
|
||||
if not image_url:
|
||||
return {'ret': False,
|
||||
'msg': "image_url option required for VirtualMediaEject"}
|
||||
|
||||
# locate and read the VirtualMedia resources
|
||||
response = self.get_request(self.root_uri + self.manager_uri)
|
||||
# Given resource_type, use the proper URI
|
||||
if resource_type == 'Systems':
|
||||
resource_uri = self.systems_uri
|
||||
elif resource_type == 'Manager':
|
||||
resource_uri = self.manager_uri
|
||||
response = self.get_request(self.root_uri + resource_uri)
|
||||
if response['ret'] is False:
|
||||
return response
|
||||
data = response['data']
|
||||
@@ -2395,7 +2424,7 @@ class RedfishUtils(object):
|
||||
# Some hardware (such as iLO 4) only supports the Image property on the PATCH operation
|
||||
# Inserted is not writable
|
||||
image_only = False
|
||||
if data["FirmwareVersion"].startswith("iLO 4"):
|
||||
if "FirmwareVersion" in data and data["FirmwareVersion"].startswith("iLO 4"):
|
||||
image_only = True
|
||||
|
||||
if 'Supermicro' in data['Oem']:
|
||||
|
||||
@@ -32,6 +32,17 @@ class WdcRedfishUtils(RedfishUtils):
|
||||
UPDATE_STATUS_MESSAGE_FW_UPDATE_COMPLETED_WAITING_FOR_ACTIVATION = "FW update completed. Waiting for activation."
|
||||
UPDATE_STATUS_MESSAGE_FW_UPDATE_FAILED = "FW update failed."
|
||||
|
||||
# Dict keys for resource bodies
|
||||
# Standard keys
|
||||
ACTIONS = "Actions"
|
||||
OEM = "Oem"
|
||||
WDC = "WDC"
|
||||
TARGET = "target"
|
||||
|
||||
# Keys for specific operations
|
||||
CHASSIS_LOCATE = "#Chassis.Locate"
|
||||
CHASSIS_POWER_MODE = "#Chassis.PowerMode"
|
||||
|
||||
def __init__(self,
|
||||
creds,
|
||||
root_uris,
|
||||
@@ -409,17 +420,32 @@ class WdcRedfishUtils(RedfishUtils):
|
||||
@staticmethod
|
||||
def _get_led_locate_uri(data):
|
||||
"""Get the LED locate URI given a resource body."""
|
||||
if "Actions" not in data:
|
||||
if WdcRedfishUtils.ACTIONS not in data:
|
||||
return None
|
||||
if "Oem" not in data["Actions"]:
|
||||
if WdcRedfishUtils.OEM not in data[WdcRedfishUtils.ACTIONS]:
|
||||
return None
|
||||
if "WDC" not in data["Actions"]["Oem"]:
|
||||
if WdcRedfishUtils.WDC not in data[WdcRedfishUtils.ACTIONS][WdcRedfishUtils.OEM]:
|
||||
return None
|
||||
if "#Chassis.Locate" not in data["Actions"]["Oem"]["WDC"]:
|
||||
if WdcRedfishUtils.CHASSIS_LOCATE not in data[WdcRedfishUtils.ACTIONS][WdcRedfishUtils.OEM][WdcRedfishUtils.WDC]:
|
||||
return None
|
||||
if "target" not in data["Actions"]["Oem"]["WDC"]["#Chassis.Locate"]:
|
||||
if WdcRedfishUtils.TARGET not in data[WdcRedfishUtils.ACTIONS][WdcRedfishUtils.OEM][WdcRedfishUtils.WDC][WdcRedfishUtils.CHASSIS_LOCATE]:
|
||||
return None
|
||||
return data["Actions"]["Oem"]["WDC"]["#Chassis.Locate"]["target"]
|
||||
return data[WdcRedfishUtils.ACTIONS][WdcRedfishUtils.OEM][WdcRedfishUtils.WDC][WdcRedfishUtils.CHASSIS_LOCATE][WdcRedfishUtils.TARGET]
|
||||
|
||||
@staticmethod
|
||||
def _get_power_mode_uri(data):
|
||||
"""Get the Power Mode URI given a resource body."""
|
||||
if WdcRedfishUtils.ACTIONS not in data:
|
||||
return None
|
||||
if WdcRedfishUtils.OEM not in data[WdcRedfishUtils.ACTIONS]:
|
||||
return None
|
||||
if WdcRedfishUtils.WDC not in data[WdcRedfishUtils.ACTIONS][WdcRedfishUtils.OEM]:
|
||||
return None
|
||||
if WdcRedfishUtils.CHASSIS_POWER_MODE not in data[WdcRedfishUtils.ACTIONS][WdcRedfishUtils.OEM][WdcRedfishUtils.WDC]:
|
||||
return None
|
||||
if WdcRedfishUtils.TARGET not in data[WdcRedfishUtils.ACTIONS][WdcRedfishUtils.OEM][WdcRedfishUtils.WDC][WdcRedfishUtils.CHASSIS_POWER_MODE]:
|
||||
return None
|
||||
return data[WdcRedfishUtils.ACTIONS][WdcRedfishUtils.OEM][WdcRedfishUtils.WDC][WdcRedfishUtils.CHASSIS_POWER_MODE][WdcRedfishUtils.TARGET]
|
||||
|
||||
def manage_indicator_led(self, command, resource_uri):
|
||||
key = 'IndicatorLED'
|
||||
@@ -452,3 +478,43 @@ class WdcRedfishUtils(RedfishUtils):
|
||||
return {'ret': False, 'msg': 'Invalid command'}
|
||||
|
||||
return result
|
||||
|
||||
def manage_chassis_power_mode(self, command):
|
||||
return self.manage_power_mode(command, self.chassis_uri)
|
||||
|
||||
def manage_power_mode(self, command, resource_uri=None):
|
||||
if resource_uri is None:
|
||||
resource_uri = self.chassis_uri
|
||||
|
||||
payloads = {'PowerModeNormal': 'Normal', 'PowerModeLow': 'Low'}
|
||||
requested_power_mode = payloads[command]
|
||||
|
||||
result = {}
|
||||
response = self.get_request(self.root_uri + resource_uri)
|
||||
if response['ret'] is False:
|
||||
return response
|
||||
result['ret'] = True
|
||||
data = response['data']
|
||||
|
||||
# Make sure the response includes Oem.WDC.PowerMode, and get current power mode
|
||||
power_mode = 'PowerMode'
|
||||
if WdcRedfishUtils.OEM not in data or WdcRedfishUtils.WDC not in data[WdcRedfishUtils.OEM] or\
|
||||
power_mode not in data[WdcRedfishUtils.OEM][WdcRedfishUtils.WDC]:
|
||||
return {'ret': False, 'msg': 'Resource does not support Oem.WDC.PowerMode'}
|
||||
current_power_mode = data[WdcRedfishUtils.OEM][WdcRedfishUtils.WDC][power_mode]
|
||||
if current_power_mode == requested_power_mode:
|
||||
return {'ret': True, 'changed': False}
|
||||
|
||||
power_mode_uri = self._get_power_mode_uri(data)
|
||||
if power_mode_uri is None:
|
||||
return {'ret': False, 'msg': 'Power Mode URI not found.'}
|
||||
|
||||
if command in payloads.keys():
|
||||
payload = {'PowerMode': payloads[command]}
|
||||
response = self.post_request(self.root_uri + power_mode_uri, payload)
|
||||
if response['ret'] is False:
|
||||
return response
|
||||
else:
|
||||
return {'ret': False, 'msg': 'Invalid command'}
|
||||
|
||||
return result
|
||||
|
||||
@@ -46,12 +46,12 @@ options:
|
||||
type: str
|
||||
image_id:
|
||||
description:
|
||||
- Image ID used to launch instances. Required when C(state=present) and creating new ECS instances.
|
||||
- Image ID used to launch instances. Required when I(state=present) and creating new ECS instances.
|
||||
aliases: ['image']
|
||||
type: str
|
||||
instance_type:
|
||||
description:
|
||||
- Instance type used to launch instances. Required when C(state=present) and creating new ECS instances.
|
||||
- Instance type used to launch instances. Required when I(state=present) and creating new ECS instances.
|
||||
aliases: ['type']
|
||||
type: str
|
||||
security_groups:
|
||||
@@ -90,7 +90,7 @@ options:
|
||||
max_bandwidth_out:
|
||||
description:
|
||||
- Maximum outgoing bandwidth to the public network, measured in Mbps (Megabits per second).
|
||||
Required when C(allocate_public_ip=True). Ignored when C(allocate_public_ip=False).
|
||||
Required when I(allocate_public_ip=true). Ignored when I(allocate_public_ip=false).
|
||||
default: 0
|
||||
type: int
|
||||
host_name:
|
||||
@@ -101,7 +101,7 @@ options:
|
||||
description:
|
||||
- Specifies whether to add sequential suffixes to the host_name.
|
||||
The sequential suffix ranges from 001 to 999.
|
||||
default: False
|
||||
default: false
|
||||
type: bool
|
||||
version_added: '0.2.0'
|
||||
password:
|
||||
@@ -143,7 +143,7 @@ options:
|
||||
allocate_public_ip:
|
||||
description:
|
||||
- Whether allocate a public ip for the new instance.
|
||||
default: False
|
||||
default: false
|
||||
aliases: [ 'assign_public_ip' ]
|
||||
type: bool
|
||||
instance_charge_type:
|
||||
@@ -154,7 +154,7 @@ options:
|
||||
type: str
|
||||
period:
|
||||
description:
|
||||
- The charge duration of the instance, in month. Required when C(instance_charge_type=PrePaid).
|
||||
- The charge duration of the instance, in months. Required when I(instance_charge_type=PrePaid).
|
||||
- The valid value are [1-9, 12, 24, 36].
|
||||
default: 1
|
||||
type: int
|
||||
@@ -162,10 +162,10 @@ options:
|
||||
description:
|
||||
- Whether automate renew the charge of the instance.
|
||||
type: bool
|
||||
default: False
|
||||
default: false
|
||||
auto_renew_period:
|
||||
description:
|
||||
- The duration of the automatic renew the charge of the instance. Required when C(auto_renew=True).
|
||||
- The duration of the automatic renew the charge of the instance. Required when I(auto_renew=true).
|
||||
choices: [1, 2, 3, 6, 12]
|
||||
type: int
|
||||
instance_ids:
|
||||
@@ -177,7 +177,7 @@ options:
|
||||
force:
|
||||
description:
|
||||
- Whether the current operation needs to be execute forcibly.
|
||||
default: False
|
||||
default: false
|
||||
type: bool
|
||||
tags:
|
||||
description:
|
||||
@@ -189,7 +189,7 @@ options:
|
||||
description:
|
||||
- Delete any tags not specified in the task that are on the instance.
|
||||
If True, it means you have to specify all the desired tags on each task affecting an instance.
|
||||
default: False
|
||||
default: false
|
||||
type: bool
|
||||
version_added: '0.2.0'
|
||||
key_name:
|
||||
@@ -217,32 +217,32 @@ options:
|
||||
version_added: '0.2.0'
|
||||
spot_strategy:
|
||||
description:
|
||||
- The bidding mode of the pay-as-you-go instance. This parameter is valid when InstanceChargeType is set to PostPaid.
|
||||
- The bidding mode of the pay-as-you-go instance. This parameter is valid when InstanceChargeType is set to PostPaid.
|
||||
choices: ['NoSpot', 'SpotWithPriceLimit', 'SpotAsPriceGo']
|
||||
default: 'NoSpot'
|
||||
type: str
|
||||
version_added: '0.2.0'
|
||||
period_unit:
|
||||
description:
|
||||
- The duration unit that you will buy the resource. It is valid when C(instance_charge_type=PrePaid)
|
||||
- The duration unit that you will buy the resource. It is valid when I(instance_charge_type=PrePaid).
|
||||
choices: ['Month', 'Week']
|
||||
default: 'Month'
|
||||
type: str
|
||||
version_added: '0.2.0'
|
||||
dry_run:
|
||||
description:
|
||||
- Specifies whether to send a dry-run request.
|
||||
- If I(dry_run=True), Only a dry-run request is sent and no instance is created. The system checks whether the
|
||||
required parameters are set, and validates the request format, service permissions, and available ECS instances.
|
||||
If the validation fails, the corresponding error code is returned. If the validation succeeds, the DryRunOperation error code is returned.
|
||||
- If I(dry_run=False), A request is sent. If the validation succeeds, the instance is created.
|
||||
default: False
|
||||
- Specifies whether to send a dry-run request.
|
||||
- If I(dry_run=true), Only a dry-run request is sent and no instance is created. The system checks whether the
|
||||
required parameters are set, and validates the request format, service permissions, and available ECS instances.
|
||||
If the validation fails, the corresponding error code is returned. If the validation succeeds, the DryRunOperation error code is returned.
|
||||
- If I(dry_run=false), A request is sent. If the validation succeeds, the instance is created.
|
||||
default: false
|
||||
type: bool
|
||||
version_added: '0.2.0'
|
||||
include_data_disks:
|
||||
description:
|
||||
- Whether to change instance disks charge type when changing instance charge type.
|
||||
default: True
|
||||
- Whether to change instance disks charge type when changing instance charge type.
|
||||
default: true
|
||||
type: bool
|
||||
version_added: '0.2.0'
|
||||
author:
|
||||
@@ -265,7 +265,7 @@ EXAMPLES = '''
|
||||
image: ubuntu1404_64_40G_cloudinit_20160727.raw
|
||||
instance_type: ecs.n4.small
|
||||
vswitch_id: vsw-abcd1234
|
||||
assign_public_ip: True
|
||||
assign_public_ip: true
|
||||
max_bandwidth_out: 10
|
||||
host_name: myhost
|
||||
password: mypassword
|
||||
@@ -275,7 +275,7 @@ EXAMPLES = '''
|
||||
security_groups: ["sg-f2rwnfh23r"]
|
||||
|
||||
instance_ids: ["i-abcd12346", "i-abcd12345"]
|
||||
force: True
|
||||
force: true
|
||||
|
||||
tasks:
|
||||
- name: Launch ECS instance in VPC network
|
||||
@@ -617,18 +617,10 @@ ids:
|
||||
|
||||
import re
|
||||
import time
|
||||
import traceback
|
||||
from ansible.module_utils.basic import AnsibleModule, missing_required_lib
|
||||
from ansible_collections.community.general.plugins.module_utils.alicloud_ecs import ecs_argument_spec, ecs_connect
|
||||
|
||||
HAS_FOOTMARK = False
|
||||
FOOTMARK_IMP_ERR = None
|
||||
try:
|
||||
from footmark.exception import ECSResponseError
|
||||
HAS_FOOTMARK = True
|
||||
except ImportError:
|
||||
FOOTMARK_IMP_ERR = traceback.format_exc()
|
||||
HAS_FOOTMARK = False
|
||||
from ansible_collections.community.general.plugins.module_utils.alicloud_ecs import (
|
||||
ecs_argument_spec, ecs_connect, FOOTMARK_IMP_ERR, HAS_FOOTMARK
|
||||
)
|
||||
|
||||
|
||||
def get_instances_info(connection, ids):
|
||||
|
||||
@@ -341,18 +341,10 @@ ids:
|
||||
sample: [i-12345er, i-3245fs]
|
||||
'''
|
||||
|
||||
import traceback
|
||||
from ansible.module_utils.basic import AnsibleModule, missing_required_lib
|
||||
from ansible_collections.community.general.plugins.module_utils.alicloud_ecs import ecs_argument_spec, ecs_connect
|
||||
|
||||
HAS_FOOTMARK = False
|
||||
FOOTMARK_IMP_ERR = None
|
||||
try:
|
||||
from footmark.exception import ECSResponseError
|
||||
HAS_FOOTMARK = True
|
||||
except ImportError:
|
||||
FOOTMARK_IMP_ERR = traceback.format_exc()
|
||||
HAS_FOOTMARK = False
|
||||
from ansible_collections.community.general.plugins.module_utils.alicloud_ecs import (
|
||||
ecs_argument_spec, ecs_connect, FOOTMARK_IMP_ERR, HAS_FOOTMARK
|
||||
)
|
||||
|
||||
|
||||
def main():
|
||||
|
||||
@@ -26,18 +26,18 @@ options:
|
||||
backend:
|
||||
description:
|
||||
- Define the backend to use for the container.
|
||||
required: True
|
||||
required: true
|
||||
choices: ["docker", "ostree"]
|
||||
type: str
|
||||
name:
|
||||
description:
|
||||
- Name of the container.
|
||||
required: True
|
||||
required: true
|
||||
type: str
|
||||
image:
|
||||
description:
|
||||
- The image to use to install the container.
|
||||
required: True
|
||||
required: true
|
||||
type: str
|
||||
rootfs:
|
||||
description:
|
||||
|
||||
@@ -31,7 +31,7 @@ options:
|
||||
name:
|
||||
description:
|
||||
- Name of the container image.
|
||||
required: True
|
||||
required: true
|
||||
type: str
|
||||
state:
|
||||
description:
|
||||
@@ -44,7 +44,7 @@ options:
|
||||
description:
|
||||
- Start or Stop the container.
|
||||
type: bool
|
||||
default: 'yes'
|
||||
default: true
|
||||
'''
|
||||
|
||||
EXAMPLES = r'''
|
||||
|
||||
@@ -19,17 +19,17 @@ options:
|
||||
description:
|
||||
- The name of the Anti Affinity Policy.
|
||||
type: str
|
||||
required: True
|
||||
required: true
|
||||
location:
|
||||
description:
|
||||
- Datacenter in which the policy lives/should live.
|
||||
type: str
|
||||
required: True
|
||||
required: true
|
||||
state:
|
||||
description:
|
||||
- Whether to create or delete the policy.
|
||||
type: str
|
||||
required: False
|
||||
required: false
|
||||
default: present
|
||||
choices: ['present','absent']
|
||||
requirements:
|
||||
@@ -55,7 +55,7 @@ EXAMPLES = '''
|
||||
---
|
||||
- name: Create AA Policy
|
||||
hosts: localhost
|
||||
gather_facts: False
|
||||
gather_facts: false
|
||||
connection: local
|
||||
tasks:
|
||||
- name: Create an Anti Affinity Policy
|
||||
@@ -71,7 +71,7 @@ EXAMPLES = '''
|
||||
|
||||
- name: Delete AA Policy
|
||||
hosts: localhost
|
||||
gather_facts: False
|
||||
gather_facts: false
|
||||
connection: local
|
||||
tasks:
|
||||
- name: Delete an Anti Affinity Policy
|
||||
|
||||
@@ -20,7 +20,7 @@ options:
|
||||
description:
|
||||
- The alias of your CLC Account
|
||||
type: str
|
||||
required: True
|
||||
required: true
|
||||
name:
|
||||
description:
|
||||
- The name of the alert policy. This is mutually exclusive with id
|
||||
@@ -81,7 +81,7 @@ EXAMPLES = '''
|
||||
---
|
||||
- name: Create Alert Policy Example
|
||||
hosts: localhost
|
||||
gather_facts: False
|
||||
gather_facts: false
|
||||
connection: local
|
||||
tasks:
|
||||
- name: Create an Alert Policy for disk above 80% for 5 minutes
|
||||
@@ -102,7 +102,7 @@ EXAMPLES = '''
|
||||
|
||||
- name: Delete Alert Policy Example
|
||||
hosts: localhost
|
||||
gather_facts: False
|
||||
gather_facts: false
|
||||
connection: local
|
||||
tasks:
|
||||
- name: Delete an Alert Policy
|
||||
|
||||
@@ -19,24 +19,24 @@ options:
|
||||
description:
|
||||
- A list of server Ids to deploy the blue print package.
|
||||
type: list
|
||||
required: True
|
||||
required: true
|
||||
elements: str
|
||||
package_id:
|
||||
description:
|
||||
- The package id of the blue print.
|
||||
type: str
|
||||
required: True
|
||||
required: true
|
||||
package_params:
|
||||
description:
|
||||
- The dictionary of arguments required to deploy the blue print.
|
||||
type: dict
|
||||
default: {}
|
||||
required: False
|
||||
required: false
|
||||
state:
|
||||
description:
|
||||
- Whether to install or uninstall the package. Currently it supports only "present" for install action.
|
||||
type: str
|
||||
required: False
|
||||
required: false
|
||||
default: present
|
||||
choices: ['present']
|
||||
wait:
|
||||
@@ -44,7 +44,7 @@ options:
|
||||
- Whether to wait for the tasks to finish before returning.
|
||||
type: str
|
||||
default: 'True'
|
||||
required: False
|
||||
required: false
|
||||
requirements:
|
||||
- python = 2.7
|
||||
- requests >= 2.5.0
|
||||
|
||||
@@ -19,7 +19,7 @@ options:
|
||||
description:
|
||||
- Target datacenter for the firewall policy
|
||||
type: str
|
||||
required: True
|
||||
required: true
|
||||
state:
|
||||
description:
|
||||
- Whether to create or delete the firewall policy
|
||||
@@ -53,7 +53,7 @@ options:
|
||||
description:
|
||||
- CLC alias for the source account
|
||||
type: str
|
||||
required: True
|
||||
required: true
|
||||
destination_account_alias:
|
||||
description:
|
||||
- CLC alias for the destination account
|
||||
@@ -90,7 +90,7 @@ EXAMPLES = '''
|
||||
---
|
||||
- name: Create Firewall Policy
|
||||
hosts: localhost
|
||||
gather_facts: False
|
||||
gather_facts: false
|
||||
connection: local
|
||||
tasks:
|
||||
- name: Create / Verify an Firewall Policy at CenturyLink Cloud
|
||||
@@ -105,7 +105,7 @@ EXAMPLES = '''
|
||||
|
||||
- name: Delete Firewall Policy
|
||||
hosts: localhost
|
||||
gather_facts: False
|
||||
gather_facts: false
|
||||
connection: local
|
||||
tasks:
|
||||
- name: Delete an Firewall Policy at CenturyLink Cloud
|
||||
|
||||
@@ -20,23 +20,23 @@ options:
|
||||
description:
|
||||
- The name of the Server Group
|
||||
type: str
|
||||
required: True
|
||||
required: true
|
||||
description:
|
||||
description:
|
||||
- A description of the Server Group
|
||||
type: str
|
||||
required: False
|
||||
required: false
|
||||
parent:
|
||||
description:
|
||||
- The parent group of the server group. If parent is not provided, it creates the group at top level.
|
||||
type: str
|
||||
required: False
|
||||
required: false
|
||||
location:
|
||||
description:
|
||||
- Datacenter to create the group in. If location is not provided, the group gets created in the default datacenter
|
||||
associated with the account
|
||||
type: str
|
||||
required: False
|
||||
required: false
|
||||
state:
|
||||
description:
|
||||
- Whether to create or delete the group
|
||||
@@ -47,8 +47,8 @@ options:
|
||||
description:
|
||||
- Whether to wait for the tasks to finish before returning.
|
||||
type: bool
|
||||
default: True
|
||||
required: False
|
||||
default: true
|
||||
required: false
|
||||
requirements:
|
||||
- python = 2.7
|
||||
- requests >= 2.5.0
|
||||
@@ -73,7 +73,7 @@ EXAMPLES = '''
|
||||
---
|
||||
- name: Create Server Group
|
||||
hosts: localhost
|
||||
gather_facts: False
|
||||
gather_facts: false
|
||||
connection: local
|
||||
tasks:
|
||||
- name: Create / Verify a Server Group at CenturyLink Cloud
|
||||
@@ -90,7 +90,7 @@ EXAMPLES = '''
|
||||
# Delete a Server Group
|
||||
- name: Delete Server Group
|
||||
hosts: localhost
|
||||
gather_facts: False
|
||||
gather_facts: false
|
||||
connection: local
|
||||
tasks:
|
||||
- name: Delete / Verify Absent a Server Group at CenturyLink Cloud
|
||||
|
||||
@@ -20,7 +20,7 @@ options:
|
||||
description:
|
||||
- The name of the loadbalancer
|
||||
type: str
|
||||
required: True
|
||||
required: true
|
||||
description:
|
||||
description:
|
||||
- A description for the loadbalancer
|
||||
@@ -29,12 +29,12 @@ options:
|
||||
description:
|
||||
- The alias of your CLC Account
|
||||
type: str
|
||||
required: True
|
||||
required: true
|
||||
location:
|
||||
description:
|
||||
- The location of the datacenter where the load balancer resides in
|
||||
type: str
|
||||
required: True
|
||||
required: true
|
||||
method:
|
||||
description:
|
||||
-The balancing method for the load balancer pool
|
||||
|
||||
@@ -19,7 +19,7 @@ options:
|
||||
description:
|
||||
- A list of server Ids to modify.
|
||||
type: list
|
||||
required: True
|
||||
required: true
|
||||
elements: str
|
||||
cpu:
|
||||
description:
|
||||
@@ -59,7 +59,7 @@ options:
|
||||
description:
|
||||
- Whether to wait for the provisioning tasks to finish before returning.
|
||||
type: bool
|
||||
default: 'yes'
|
||||
default: true
|
||||
requirements:
|
||||
- python = 2.7
|
||||
- requests >= 2.5.0
|
||||
|
||||
@@ -30,7 +30,7 @@ options:
|
||||
description:
|
||||
- A list of servers to create public ips on.
|
||||
type: list
|
||||
required: True
|
||||
required: true
|
||||
elements: str
|
||||
state:
|
||||
description:
|
||||
@@ -43,7 +43,7 @@ options:
|
||||
description:
|
||||
- Whether to wait for the tasks to finish before returning.
|
||||
type: bool
|
||||
default: 'yes'
|
||||
default: true
|
||||
requirements:
|
||||
- python = 2.7
|
||||
- requests >= 2.5.0
|
||||
@@ -66,7 +66,7 @@ EXAMPLES = '''
|
||||
|
||||
- name: Add Public IP to Server
|
||||
hosts: localhost
|
||||
gather_facts: False
|
||||
gather_facts: false
|
||||
connection: local
|
||||
tasks:
|
||||
- name: Create Public IP For Servers
|
||||
@@ -86,7 +86,7 @@ EXAMPLES = '''
|
||||
|
||||
- name: Delete Public IP from Server
|
||||
hosts: localhost
|
||||
gather_facts: False
|
||||
gather_facts: false
|
||||
connection: local
|
||||
tasks:
|
||||
- name: Create Public IP For Servers
|
||||
|
||||
@@ -25,7 +25,7 @@ options:
|
||||
description:
|
||||
- Whether to add a public ip to the server
|
||||
type: bool
|
||||
default: 'no'
|
||||
default: false
|
||||
alias:
|
||||
description:
|
||||
- The account alias to provision the servers under.
|
||||
@@ -96,8 +96,8 @@ options:
|
||||
description:
|
||||
- Whether to create the server as 'Managed' or not.
|
||||
type: bool
|
||||
default: 'no'
|
||||
required: False
|
||||
default: false
|
||||
required: false
|
||||
memory:
|
||||
description:
|
||||
- Memory in GB.
|
||||
@@ -194,7 +194,7 @@ options:
|
||||
description:
|
||||
- Whether to wait for the provisioning tasks to finish before returning.
|
||||
type: bool
|
||||
default: 'yes'
|
||||
default: true
|
||||
requirements:
|
||||
- python = 2.7
|
||||
- requests >= 2.5.0
|
||||
|
||||
@@ -19,26 +19,26 @@ options:
|
||||
description:
|
||||
- The list of CLC server Ids.
|
||||
type: list
|
||||
required: True
|
||||
required: true
|
||||
elements: str
|
||||
expiration_days:
|
||||
description:
|
||||
- The number of days to keep the server snapshot before it expires.
|
||||
type: int
|
||||
default: 7
|
||||
required: False
|
||||
required: false
|
||||
state:
|
||||
description:
|
||||
- The state to insure that the provided resources are in.
|
||||
type: str
|
||||
default: 'present'
|
||||
required: False
|
||||
required: false
|
||||
choices: ['present', 'absent', 'restore']
|
||||
wait:
|
||||
description:
|
||||
- Whether to wait for the provisioning tasks to finish before returning.
|
||||
default: 'True'
|
||||
required: False
|
||||
required: false
|
||||
type: str
|
||||
requirements:
|
||||
- python = 2.7
|
||||
@@ -66,7 +66,7 @@ EXAMPLES = '''
|
||||
- UC1TEST-SVR01
|
||||
- UC1TEST-SVR02
|
||||
expiration_days: 10
|
||||
wait: True
|
||||
wait: true
|
||||
state: present
|
||||
|
||||
- name: Restore server snapshot
|
||||
@@ -74,7 +74,7 @@ EXAMPLES = '''
|
||||
server_ids:
|
||||
- UC1TEST-SVR01
|
||||
- UC1TEST-SVR02
|
||||
wait: True
|
||||
wait: true
|
||||
state: restore
|
||||
|
||||
- name: Delete server snapshot
|
||||
@@ -82,7 +82,7 @@ EXAMPLES = '''
|
||||
server_ids:
|
||||
- UC1TEST-SVR01
|
||||
- UC1TEST-SVR02
|
||||
wait: True
|
||||
wait: true
|
||||
state: absent
|
||||
'''
|
||||
|
||||
|
||||
@@ -58,7 +58,7 @@ options:
|
||||
- If C(False), the module will fail under these conditions.
|
||||
- This is intended to prevent accidental expansion of a VLAN's network (since this operation is not reversible).
|
||||
type: bool
|
||||
default: 'no'
|
||||
default: false
|
||||
'''
|
||||
|
||||
EXAMPLES = '''
|
||||
@@ -72,7 +72,7 @@ EXAMPLES = '''
|
||||
private_ipv4_base_address: 192.168.23.0
|
||||
private_ipv4_prefix_size: 24
|
||||
state: present
|
||||
wait: yes
|
||||
wait: true
|
||||
|
||||
- name: Read / get VLAN details
|
||||
community.general.dimensiondata_vlan:
|
||||
@@ -81,7 +81,7 @@ EXAMPLES = '''
|
||||
network_domain: test_network
|
||||
name: my_vlan1
|
||||
state: readonly
|
||||
wait: yes
|
||||
wait: true
|
||||
|
||||
- name: Delete a VLAN
|
||||
community.general.dimensiondata_vlan:
|
||||
@@ -90,7 +90,7 @@ EXAMPLES = '''
|
||||
network_domain: test_network
|
||||
name: my_vlan_1
|
||||
state: absent
|
||||
wait: yes
|
||||
wait: true
|
||||
'''
|
||||
|
||||
RETURN = '''
|
||||
|
||||
@@ -36,7 +36,7 @@ options:
|
||||
description:
|
||||
- Suppress email invitation when creating collaborator
|
||||
type: bool
|
||||
default: "no"
|
||||
default: false
|
||||
user:
|
||||
type: str
|
||||
description:
|
||||
|
||||
@@ -135,7 +135,7 @@ EXAMPLES = '''
|
||||
hwc_vpc_subnet:
|
||||
gateway_ip: "192.168.100.32"
|
||||
name: "ansible_network_subnet_test"
|
||||
dhcp_enable: True
|
||||
dhcp_enable: true
|
||||
vpc_id: "{{ vpc.id }}"
|
||||
cidr: "192.168.100.0/26"
|
||||
register: subnet
|
||||
|
||||
@@ -119,7 +119,7 @@ EXAMPLES = '''
|
||||
hwc_vpc_subnet:
|
||||
gateway_ip: "192.168.100.32"
|
||||
name: "ansible_network_subnet_test"
|
||||
dhcp_enable: True
|
||||
dhcp_enable: true
|
||||
vpc_id: "{{ vpc.id }}"
|
||||
cidr: "192.168.100.0/26"
|
||||
register: subnet
|
||||
|
||||
@@ -63,7 +63,7 @@ EXAMPLES = '''
|
||||
hwc_vpc_subnet:
|
||||
gateway_ip: "192.168.100.32"
|
||||
name: "ansible_network_subnet_test"
|
||||
dhcp_enable: True
|
||||
dhcp_enable: true
|
||||
vpc_id: "{{ vpc.id }}"
|
||||
cidr: "192.168.100.0/26"
|
||||
register: subnet
|
||||
|
||||
@@ -110,7 +110,7 @@ EXAMPLES = '''
|
||||
cidr: "192.168.100.0/26"
|
||||
gateway_ip: "192.168.100.32"
|
||||
name: "ansible_network_subnet_test"
|
||||
dhcp_enable: True
|
||||
dhcp_enable: true
|
||||
'''
|
||||
|
||||
RETURN = '''
|
||||
|
||||
@@ -26,7 +26,7 @@ options:
|
||||
- Linode API key.
|
||||
- C(LINODE_API_KEY) env variable can be used instead.
|
||||
type: str
|
||||
required: yes
|
||||
required: true
|
||||
name:
|
||||
description:
|
||||
- Name to give the instance (alphanumeric, dashes, underscore).
|
||||
@@ -185,10 +185,10 @@ EXAMPLES = '''
|
||||
datacenter: 2
|
||||
distribution: 99
|
||||
password: 'superSecureRootPassword'
|
||||
private_ip: yes
|
||||
private_ip: true
|
||||
ssh_pub_key: 'ssh-rsa qwerty'
|
||||
swap: 768
|
||||
wait: yes
|
||||
wait: true
|
||||
wait_timeout: 600
|
||||
state: present
|
||||
delegate_to: localhost
|
||||
@@ -203,21 +203,21 @@ EXAMPLES = '''
|
||||
distribution: 99
|
||||
kernel_id: 138
|
||||
password: 'superSecureRootPassword'
|
||||
private_ip: yes
|
||||
private_ip: true
|
||||
ssh_pub_key: 'ssh-rsa qwerty'
|
||||
swap: 768
|
||||
wait: yes
|
||||
wait: true
|
||||
wait_timeout: 600
|
||||
state: present
|
||||
alert_bwquota_enabled: True
|
||||
alert_bwquota_enabled: true
|
||||
alert_bwquota_threshold: 80
|
||||
alert_bwin_enabled: True
|
||||
alert_bwin_enabled: true
|
||||
alert_bwin_threshold: 10
|
||||
alert_cpu_enabled: True
|
||||
alert_cpu_enabled: true
|
||||
alert_cpu_threshold: 210
|
||||
alert_bwout_enabled: True
|
||||
alert_bwout_enabled: true
|
||||
alert_bwout_threshold: 10
|
||||
alert_diskio_enabled: True
|
||||
alert_diskio_enabled: true
|
||||
alert_diskio_threshold: 10000
|
||||
backupweeklyday: 1
|
||||
backupwindow: 2
|
||||
@@ -225,7 +225,7 @@ EXAMPLES = '''
|
||||
additional_disks:
|
||||
- {Label: 'disk1', Size: 2500, Type: 'raw'}
|
||||
- {Label: 'newdisk', Size: 2000}
|
||||
watchdog: True
|
||||
watchdog: true
|
||||
delegate_to: localhost
|
||||
register: linode_creation
|
||||
|
||||
@@ -239,7 +239,7 @@ EXAMPLES = '''
|
||||
password: 'superSecureRootPassword'
|
||||
ssh_pub_key: 'ssh-rsa qwerty'
|
||||
swap: 768
|
||||
wait: yes
|
||||
wait: true
|
||||
wait_timeout: 600
|
||||
state: present
|
||||
delegate_to: localhost
|
||||
|
||||
@@ -91,7 +91,7 @@ options:
|
||||
description:
|
||||
- Enable a container log for host actions to the container.
|
||||
type: bool
|
||||
default: 'no'
|
||||
default: false
|
||||
container_log_level:
|
||||
choices:
|
||||
- Info
|
||||
@@ -119,13 +119,13 @@ options:
|
||||
- This is not supported by all container storage backends.
|
||||
- Enabling this may fail if the backing store does not support snapshots.
|
||||
type: bool
|
||||
default: 'no'
|
||||
default: false
|
||||
archive:
|
||||
description:
|
||||
- Create an archive of a container.
|
||||
- This will create a tarball of the running container.
|
||||
type: bool
|
||||
default: 'no'
|
||||
default: false
|
||||
archive_path:
|
||||
description:
|
||||
- Path the save the archived container.
|
||||
@@ -413,7 +413,7 @@ lxc_container:
|
||||
description: if the container was cloned
|
||||
returned: success, when clone_name is specified
|
||||
type: bool
|
||||
sample: True
|
||||
sample: true
|
||||
"""
|
||||
|
||||
import os
|
||||
|
||||
@@ -42,7 +42,7 @@ EXAMPLES = '''
|
||||
- name: Submit DNS reload and poll
|
||||
community.general.memset_dns_reload:
|
||||
api_key: 5eb86c9196ab03919abcf03857163741
|
||||
poll: True
|
||||
poll: true
|
||||
delegate_to: localhost
|
||||
'''
|
||||
|
||||
|
||||
@@ -142,7 +142,7 @@ memset_api:
|
||||
description: Adds the current domain onto the address field for C(CNAME), C(MX), C(NS) and C(SRV) types.
|
||||
returned: always
|
||||
type: bool
|
||||
sample: False
|
||||
sample: false
|
||||
ttl:
|
||||
description: Record TTL.
|
||||
returned: always
|
||||
|
||||
@@ -86,7 +86,7 @@ options:
|
||||
onboot:
|
||||
description:
|
||||
- specifies whether a VM will be started during system bootup
|
||||
- This option has no default unless I(proxmox_default_behavior) is set to C(compatiblity); then the default is C(no).
|
||||
- This option has no default unless I(proxmox_default_behavior) is set to C(compatiblity); then the default is C(false).
|
||||
type: bool
|
||||
storage:
|
||||
description:
|
||||
@@ -118,7 +118,7 @@ options:
|
||||
- with C(state=present) force option allow to overwrite existing container
|
||||
- with states C(stopped) , C(restarted) allow to force stop instance
|
||||
type: bool
|
||||
default: 'no'
|
||||
default: false
|
||||
purge:
|
||||
description:
|
||||
- Remove container from all related configurations.
|
||||
@@ -140,9 +140,11 @@ options:
|
||||
type: str
|
||||
unprivileged:
|
||||
description:
|
||||
- Indicate if the container should be unprivileged
|
||||
- Indicate if the container should be unprivileged.
|
||||
- >
|
||||
The default value for this parameter is C(false) but that is deprecated
|
||||
and it will be replaced with C(true) in community.general 7.0.0.
|
||||
type: bool
|
||||
default: 'no'
|
||||
description:
|
||||
description:
|
||||
- Specify the description for the container. Only used on the configuration web interface.
|
||||
@@ -239,7 +241,7 @@ EXAMPLES = r'''
|
||||
password: 123456
|
||||
hostname: example.org
|
||||
ostemplate: 'local:vztmpl/ubuntu-14.04-x86_64.tar.gz'
|
||||
force: yes
|
||||
force: true
|
||||
|
||||
- name: Create new container with minimal options use environment PROXMOX_PASSWORD variable(you should export it before)
|
||||
community.general.proxmox:
|
||||
@@ -369,7 +371,7 @@ EXAMPLES = r'''
|
||||
api_user: root@pam
|
||||
api_password: 1q2w3e
|
||||
api_host: node1
|
||||
force: yes
|
||||
force: true
|
||||
state: stopped
|
||||
|
||||
- name: Restart container(stopped or mounted container you can't restart)
|
||||
@@ -390,11 +392,10 @@ EXAMPLES = r'''
|
||||
'''
|
||||
|
||||
import time
|
||||
import traceback
|
||||
|
||||
from ansible_collections.community.general.plugins.module_utils.version import LooseVersion
|
||||
|
||||
from ansible.module_utils.basic import AnsibleModule, env_fallback
|
||||
from ansible.module_utils.basic import AnsibleModule
|
||||
from ansible.module_utils.common.text.converters import to_native
|
||||
|
||||
from ansible_collections.community.general.plugins.module_utils.proxmox import (
|
||||
@@ -566,7 +567,7 @@ def main():
|
||||
purge=dict(type='bool', default=False),
|
||||
state=dict(default='present', choices=['present', 'absent', 'stopped', 'started', 'restarted']),
|
||||
pubkey=dict(type='str'),
|
||||
unprivileged=dict(type='bool', default=False),
|
||||
unprivileged=dict(type='bool'),
|
||||
description=dict(type='str'),
|
||||
hookscript=dict(type='str'),
|
||||
proxmox_default_behavior=dict(type='str', default='no_defaults', choices=['compatibility', 'no_defaults']),
|
||||
@@ -608,6 +609,14 @@ def main():
|
||||
timeout = module.params['timeout']
|
||||
clone = module.params['clone']
|
||||
|
||||
if module.params['unprivileged'] is None:
|
||||
module.params['unprivileged'] = False
|
||||
module.deprecate(
|
||||
'The default value `false` for the parameter "unprivileged" is deprecated and it will be replaced with `true`',
|
||||
version='7.0.0',
|
||||
collection_name='community.general'
|
||||
)
|
||||
|
||||
if module.params['proxmox_default_behavior'] == 'compatibility':
|
||||
old_default_values = dict(
|
||||
disk="3",
|
||||
|
||||
@@ -75,7 +75,7 @@ proxmox_domains:
|
||||
'''
|
||||
|
||||
|
||||
from ansible.module_utils.basic import AnsibleModule, missing_required_lib
|
||||
from ansible.module_utils.basic import AnsibleModule
|
||||
from ansible_collections.community.general.plugins.module_utils.proxmox import (
|
||||
proxmox_auth_argument_spec, ProxmoxAnsible)
|
||||
|
||||
|
||||
@@ -72,7 +72,7 @@ proxmox_groups:
|
||||
'''
|
||||
|
||||
|
||||
from ansible.module_utils.basic import AnsibleModule, missing_required_lib
|
||||
from ansible.module_utils.basic import AnsibleModule
|
||||
from ansible_collections.community.general.plugins.module_utils.proxmox import (
|
||||
proxmox_auth_argument_spec, ProxmoxAnsible)
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user