mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-04-28 09:26:44 +00:00
Compare commits
98 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3f2111582d | ||
|
|
bd8634e04e | ||
|
|
1ae57fc5dd | ||
|
|
1e5e0824d2 | ||
|
|
7eaf795774 | ||
|
|
3dc25edeac | ||
|
|
a67ee6cead | ||
|
|
9c5461dc12 | ||
|
|
0b59a71ae7 | ||
|
|
720de141b5 | ||
|
|
7ec6025690 | ||
|
|
53a5cdaed7 | ||
|
|
693efb35b3 | ||
|
|
07cd51a33b | ||
|
|
c80416164b | ||
|
|
a61bc5ab34 | ||
|
|
8ac8fa0aa9 | ||
|
|
b76994ee6e | ||
|
|
746bd3ea5d | ||
|
|
68baf56ea6 | ||
|
|
87377dd23f | ||
|
|
29f028e33b | ||
|
|
196e8fe4e3 | ||
|
|
83c6d18bc0 | ||
|
|
1314b0d7b2 | ||
|
|
be94a014c8 | ||
|
|
039c3da7dc | ||
|
|
2480250f1b | ||
|
|
860f0e12c0 | ||
|
|
2f56fd7b2a | ||
|
|
084879632a | ||
|
|
4eef56b7b3 | ||
|
|
13929acf02 | ||
|
|
070bcf80c4 | ||
|
|
0cf2a5ad05 | ||
|
|
76a64ea733 | ||
|
|
115eab2cfa | ||
|
|
dbba813e23 | ||
|
|
7daf78962b | ||
|
|
cf9fff5238 | ||
|
|
d8d68babe4 | ||
|
|
3f46cdc588 | ||
|
|
ea530784b8 | ||
|
|
dc2fa05b1f | ||
|
|
b2e51272ad | ||
|
|
afba9a11af | ||
|
|
c3ac479ae2 | ||
|
|
7e367244f7 | ||
|
|
331d2c7651 | ||
|
|
b35a262378 | ||
|
|
7d400663b6 | ||
|
|
0d0884b069 | ||
|
|
dd400e8c21 | ||
|
|
a60f9bc78b | ||
|
|
47714ecf79 | ||
|
|
d15ed4135b | ||
|
|
bd61228e40 | ||
|
|
26d7c28b33 | ||
|
|
2e533daffa | ||
|
|
6c50119eab | ||
|
|
bc3435b993 | ||
|
|
370f5d8082 | ||
|
|
e77c5413c9 | ||
|
|
800ee1bae0 | ||
|
|
8de8d21062 | ||
|
|
81e71b5034 | ||
|
|
44ce63ed85 | ||
|
|
a3c9c688b9 | ||
|
|
a332ed4429 | ||
|
|
91571f8bff | ||
|
|
43856eaa6f | ||
|
|
ae87b5479a | ||
|
|
42cd462780 | ||
|
|
d871378574 | ||
|
|
983b292399 | ||
|
|
6831aa5501 | ||
|
|
2d8a94a459 | ||
|
|
f721e76fdc | ||
|
|
3eadb9d637 | ||
|
|
033582b696 | ||
|
|
974997594f | ||
|
|
fa8ce6dea8 | ||
|
|
1d90e91528 | ||
|
|
a90e2c8002 | ||
|
|
c506375f2a | ||
|
|
4def9439bd | ||
|
|
023654473b | ||
|
|
a216f15dd9 | ||
|
|
f613983cb4 | ||
|
|
c22199794d | ||
|
|
24b1d92e84 | ||
|
|
4bc44e4062 | ||
|
|
06fd6d8742 | ||
|
|
dd0ae4a003 | ||
|
|
646ca74810 | ||
|
|
d60c107818 | ||
|
|
ef2d14f24e | ||
|
|
b3cde9b8a4 |
@@ -36,7 +36,7 @@ variables:
|
||||
resources:
|
||||
containers:
|
||||
- container: default
|
||||
image: quay.io/ansible/azure-pipelines-test-container:1.7.1
|
||||
image: quay.io/ansible/azure-pipelines-test-container:1.8.0
|
||||
|
||||
pool: Standard
|
||||
|
||||
@@ -140,16 +140,12 @@ stages:
|
||||
parameters:
|
||||
testFormat: devel/{0}
|
||||
targets:
|
||||
- name: OS X 10.11
|
||||
test: osx/10.11
|
||||
- name: macOS 10.15
|
||||
test: macos/10.15
|
||||
- name: macOS 11.1
|
||||
test: macos/11.1
|
||||
- name: RHEL 7.8
|
||||
test: rhel/7.8
|
||||
- name: RHEL 8.2
|
||||
test: rhel/8.2
|
||||
- name: RHEL 7.9
|
||||
test: rhel/7.9
|
||||
- name: RHEL 8.3
|
||||
test: rhel/8.3
|
||||
- name: FreeBSD 11.4
|
||||
test: freebsd/11.4
|
||||
- name: FreeBSD 12.2
|
||||
@@ -166,8 +162,14 @@ stages:
|
||||
parameters:
|
||||
testFormat: 2.10/{0}
|
||||
targets:
|
||||
- name: OS X 10.11
|
||||
test: osx/10.11
|
||||
- name: macOS 10.15
|
||||
test: macos/10.15
|
||||
- name: macOS 11.1
|
||||
test: macos/11.1
|
||||
- name: RHEL 7.8
|
||||
test: rhel/7.8
|
||||
- name: RHEL 8.2
|
||||
test: rhel/8.2
|
||||
- name: FreeBSD 12.1
|
||||
@@ -206,16 +208,14 @@ stages:
|
||||
test: centos7
|
||||
- name: CentOS 8
|
||||
test: centos8
|
||||
- name: Fedora 31
|
||||
test: fedora31
|
||||
- name: Fedora 32
|
||||
test: fedora32
|
||||
- name: Fedora 33
|
||||
test: fedora33
|
||||
- name: openSUSE 15 py2
|
||||
test: opensuse15py2
|
||||
- name: openSUSE 15 py3
|
||||
test: opensuse15
|
||||
- name: Ubuntu 16.04
|
||||
test: ubuntu1604
|
||||
- name: Ubuntu 18.04
|
||||
test: ubuntu1804
|
||||
- name: Ubuntu 20.04
|
||||
@@ -238,6 +238,8 @@ stages:
|
||||
test: fedora32
|
||||
- name: openSUSE 15 py3
|
||||
test: opensuse15
|
||||
- name: Ubuntu 16.04
|
||||
test: ubuntu1604
|
||||
groups:
|
||||
- 2
|
||||
- 3
|
||||
|
||||
7
.github/BOTMETA.yml
vendored
7
.github/BOTMETA.yml
vendored
@@ -15,6 +15,8 @@ files:
|
||||
labels: become
|
||||
$callbacks/:
|
||||
labels: callbacks
|
||||
$callbacks/logstash.py:
|
||||
maintainers: ujenmr
|
||||
$callbacks/say.py:
|
||||
notify: chris-short
|
||||
maintainers: $team_macos
|
||||
@@ -293,7 +295,8 @@ files:
|
||||
$modules/clustering/consul/:
|
||||
maintainers: $team_consul
|
||||
$modules/clustering/etcd3.py:
|
||||
maintainers: evrardjp vfauth
|
||||
maintainers: evrardjp
|
||||
ignore: vfauth
|
||||
$modules/clustering/nomad/:
|
||||
maintainers: chris93111
|
||||
$modules/clustering/pacemaker_cluster.py:
|
||||
@@ -417,6 +420,8 @@ files:
|
||||
maintainers: orgito
|
||||
$modules/monitoring/stackdriver.py:
|
||||
maintainers: bwhaley
|
||||
$modules/monitoring/statsd.py:
|
||||
maintainers: mamercad
|
||||
$modules/monitoring/statusio_maintenance.py:
|
||||
maintainers: bhcopeland
|
||||
$modules/monitoring/uptimerobot.py:
|
||||
|
||||
362
CHANGELOG.rst
362
CHANGELOG.rst
@@ -6,6 +6,327 @@ Community General Release Notes
|
||||
|
||||
This changelog describes changes after version 1.0.0.
|
||||
|
||||
v2.2.0
|
||||
======
|
||||
|
||||
Release Summary
|
||||
---------------
|
||||
|
||||
Regular feature and bugfix release.
|
||||
|
||||
Minor Changes
|
||||
-------------
|
||||
|
||||
- bundler - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- consul - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- consul_acl - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- consul_io inventory script - conf options - allow custom configuration options via env variables (https://github.com/ansible-collections/community.general/pull/620).
|
||||
- consul_session - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- datadog_monitor - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- grove - the option ``message`` has been renamed to ``message_content``. The old name ``message`` is kept as an alias and will be removed for community.general 4.0.0. This was done because ``message`` is used internally by Ansible (https://github.com/ansible-collections/community.general/pull/1929).
|
||||
- heroku_collaborator - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- linode_v4 - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- manageiq_alert_profiles - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- manageiq_policies - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- manageiq_tags - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- manageiq_tags and manageiq_policies - added new parameter ``resource_id``. This parameter can be used instead of parameter ``resource_name`` (https://github.com/ansible-collections/community.general/pull/719).
|
||||
- module_helper module utils - ``CmdMixin.run_command()`` now accepts ``dict`` command arguments, providing the parameter and its value (https://github.com/ansible-collections/community.general/pull/1867).
|
||||
- one_host - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- one_image_info - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- one_vm - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- oneandone_firewall_policy - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- oneandone_load_balancer - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- oneandone_monitoring_policy - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- oneandone_private_network - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- oneandone_server - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- oneview_datacenter_info - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- oneview_enclosure_info - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- oneview_ethernet_network_info - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- oneview_network_set_info - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- profitbricks - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- profitbricks_volume - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- scaleway_compute - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- scaleway_lb - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- sensu_check - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- sensu_client - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- sensu_handler - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- webfaction_domain - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- webfaction_site - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- yum_versionlock - Do the lock/unlock concurrently to speed up (https://github.com/ansible-collections/community.general/pull/1912).
|
||||
|
||||
Deprecated Features
|
||||
-------------------
|
||||
|
||||
- apt_rpm - deprecated invalid parameter alias ``update-cache``, will be removed in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- composer - deprecated invalid parameter aliases ``working-dir``, ``global-command``, ``prefer-source``, ``prefer-dist``, ``no-dev``, ``no-scripts``, ``no-plugins``, ``optimize-autoloader``, ``classmap-authoritative``, ``apcu-autoloader``, ``ignore-platform-reqs``, will be removed in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- github_deploy_key - deprecated invalid parameter alias ``2fa_token``, will be removed in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- grove - the option ``message`` will be removed in community.general 4.0.0. Use the new option ``message_content`` instead (https://github.com/ansible-collections/community.general/pull/1929).
|
||||
- homebrew - deprecated invalid parameter alias ``update-brew``, will be removed in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- homebrew_cask - deprecated invalid parameter alias ``update-brew``, will be removed in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- opkg - deprecated invalid parameter alias ``update-cache``, will be removed in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- pacman - deprecated invalid parameter alias ``update-cache``, will be removed in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- puppet - deprecated undocumented parameter ``show_diff``, will be removed in 7.0.0. (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- runit - unused parameter ``dist`` marked for deprecation (https://github.com/ansible-collections/community.general/pull/1830).
|
||||
- slackpkg - deprecated invalid parameter alias ``update-cache``, will be removed in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- urmpi - deprecated invalid parameter aliases ``update-cache`` and ``no-recommends``, will be removed in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- xbps - deprecated invalid parameter alias ``update-cache``, will be removed in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
|
||||
Bugfixes
|
||||
--------
|
||||
|
||||
- bigpanda - actually use the ``deployment_message`` option (https://github.com/ansible-collections/community.general/pull/1928).
|
||||
- chef_databag lookup plugin - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- cloudforms inventory - fixed issue that non-existing (archived) VMs were synced (https://github.com/ansible-collections/community.general/pull/720).
|
||||
- cobbler_sync, cobbler_system - fix SSL/TLS certificate check when ``validate_certs`` set to ``false`` (https://github.com/ansible-collections/community.general/pull/1880).
|
||||
- consul_io inventory script - kv_groups - fix byte chain decoding for Python 3 (https://github.com/ansible-collections/community.general/pull/620).
|
||||
- deploy_helper - allow ``state=clean`` to be used without defining a ``release`` (https://github.com/ansible-collections/community.general/issues/1852).
|
||||
- diy callback plugin - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- idrac_redfish_command - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- idrac_redfish_config - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- idrac_redfish_info - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- imc_rest - explicitly logging out instead of registering the call in ```atexit``` (https://github.com/ansible-collections/community.general/issues/1735).
|
||||
- infoblox inventory script - make sure that the script also works with Ansible 2.9, and returns a more helpful error when community.general is not installed as part of Ansible 2.10/3 (https://github.com/ansible-collections/community.general/pull/1871).
|
||||
- ini_file - allows an empty string as a value for an option (https://github.com/ansible-collections/community.general/pull/1972).
|
||||
- lxc_container - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- lxd_container - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- manageiq_provider - wrapped ``dict.keys()`` with ``list`` for use in ``choices`` setting (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- memcached cache plugin - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- meta/runtime.yml - improve deprecation messages (https://github.com/ansible-collections/community.general/pull/1918).
|
||||
- net_tools.nios.api module_utils - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- nmcli - add ``method4`` and ``method6`` options (https://github.com/ansible-collections/community.general/pull/1894).
|
||||
- nmcli - ensure the ``slave-type`` option is passed to ``nmcli`` for type ``bond-slave`` (https://github.com/ansible-collections/community.general/pull/1882).
|
||||
- nsot inventory script - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- oci_vcn - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- oneandone_monitoring_policy - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- packet_volume_attachment - removed extraneous ``print`` call - old debug? (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- proxmox inventory - added handling of extra trailing slashes in the URL (https://github.com/ansible-collections/community.general/pull/1914).
|
||||
- proxmox_kvm - fix parameter ``vmid`` passed twice to ``exit_json`` while creating a virtual machine without cloning (https://github.com/ansible-collections/community.general/issues/1875, https://github.com/ansible-collections/community.general/pull/1895).
|
||||
- redfish_command - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- redfish_config - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- redhat_subscription - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- redis cache plugin - wrapped usages of ``keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- selective callback plugin - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- sensu_check - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- spotinst_aws_elastigroup - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- utm_utils module_utils - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- vdo - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- xfs_quota - the feedback for initializing project quota using xfs_quota binary from ``xfsprogs`` has changed since the version it was written for (https://github.com/ansible-collections/community.general/pull/1596).
|
||||
- zfs - some ZFS properties could be passed when the dataset/volume did not exist, but would fail if the dataset already existed, even if the property matched what was specified in the ansible task (https://github.com/ansible-collections/community.general/issues/868, https://github.com/ansible-collections/community.general/pull/1833).
|
||||
|
||||
New Plugins
|
||||
-----------
|
||||
|
||||
Filter
|
||||
~~~~~~
|
||||
|
||||
- version_sort - Sort a list according to version order instead of pure alphabetical one
|
||||
|
||||
New Modules
|
||||
-----------
|
||||
|
||||
Cloud
|
||||
~~~~~
|
||||
|
||||
misc
|
||||
^^^^
|
||||
|
||||
- proxmox_storage_info - Retrieve information about one or more Proxmox VE storages
|
||||
|
||||
Source Control
|
||||
~~~~~~~~~~~~~~
|
||||
|
||||
github
|
||||
^^^^^^
|
||||
|
||||
- github_repo - Manage your repositories on Github
|
||||
|
||||
gitlab
|
||||
^^^^^^
|
||||
|
||||
- gitlab_project_members - Manage project members on GitLab Server
|
||||
|
||||
Web Infrastructure
|
||||
~~~~~~~~~~~~~~~~~~
|
||||
|
||||
- jenkins_build - Manage jenkins builds
|
||||
|
||||
v2.1.1
|
||||
======
|
||||
|
||||
Release Summary
|
||||
---------------
|
||||
|
||||
Extraordinary bugfix release to fix a fatal bug in ``proxmox_kvm``.
|
||||
|
||||
Bugfixes
|
||||
--------
|
||||
|
||||
- proxmox_kvm - fix undefined local variable ``status`` when the parameter ``state`` is either ``stopped``, ``started``, ``restarted`` or ``absent`` (https://github.com/ansible-collections/community.general/pull/1847).
|
||||
|
||||
v2.1.0
|
||||
======
|
||||
|
||||
Release Summary
|
||||
---------------
|
||||
|
||||
Regular feature and bugfix release.
|
||||
|
||||
Minor Changes
|
||||
-------------
|
||||
|
||||
- clc_* modules - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1771).
|
||||
- datadog_monitor - add missing monitor types ``query alert``, ``trace-analytics alert``, ``rum alert`` (https://github.com/ansible-collections/community.general/pull/1723).
|
||||
- dnsimple - add CAA records to the whitelist of valid record types (https://github.com/ansible-collections/community.general/pull/1814).
|
||||
- dnsimple - elements of list parameters ``record_ids`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- gitlab_runner - elements of list parameters ``tag_list`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- homebrew_tap - add support to specify search path for ``brew`` executable (https://github.com/ansible-collections/community.general/issues/1702).
|
||||
- keycloak_client - elements of list parameters ``default_roles``, ``redirect_uris``, ``web_origins`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- librato_annotation - elements of list parameters ``links`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- lxd_container - ``client_key`` and ``client_cert`` are now of type ``path`` and no longer ``str``. A side effect is that certain expansions are made, like ``~`` is replaced by the user's home directory, and environment variables like ``$HOME`` or ``$TEMP`` are evaluated (https://github.com/ansible-collections/community.general/pull/1741).
|
||||
- lxd_container - elements of list parameter ``profiles`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- lxd_profile - ``client_key`` and ``client_cert`` are now of type ``path`` and no longer ``str``. A side effect is that certain expansions are made, like ``~`` is replaced by the user's home directory, and environment variables like ``$HOME`` or ``$TEMP`` are evaluated (https://github.com/ansible-collections/community.general/pull/1741).
|
||||
- lxd_profile - added ``merge_profile`` parameter to merge configurations from the play to an existing profile (https://github.com/ansible-collections/community.general/pull/1813).
|
||||
- mail - elements of list parameters ``to``, ``cc``, ``bcc``, ``attach``, ``headers`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- na_ontap_gather_facts - elements of list parameters ``gather_subset`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- nexmo - elements of list parameters ``dest`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- nsupdate - elements of list parameters ``value`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- oci_vcn - ``api_user_key_file`` is now of type ``path`` and no longer ``str``. A side effect is that certain expansions are made, like ``~`` is replaced by the user's home directory, and environment variables like ``$HOME`` or ``$TEMP`` are evaluated (https://github.com/ansible-collections/community.general/pull/1741).
|
||||
- omapi_host - elements of list parameters ``statements`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- onepassword_info - elements of list parameters ``search_terms`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- packet_device - elements of list parameters ``device_ids``, ``hostnames`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- pagerduty - elements of list parameters ``service`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- plugins/module_utils/oracle/oci_utils.py - elements of list parameter ``key_by`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- proxmox_kvm module - actually implemented ``vmid`` and ``status`` return values. Updated documentation to reflect current situation (https://github.com/ansible-collections/community.general/issues/1410, https://github.com/ansible-collections/community.general/pull/1715).
|
||||
- pubnub_blocks - elements of list parameters ``event_handlers`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- redfish modules - explicitly setting lists' elements to ``str`` (https://github.com/ansible-collections/community.general/pull/1761).
|
||||
- redfish_config - case insensitive search for situations where the hostname/FQDN case on iLO doesn't match variable's case (https://github.com/ansible-collections/community.general/pull/1744).
|
||||
- redhat_subscription - elements of list parameters ``pool_ids``, ``addons`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- rocketchat - elements of list parameters ``attachments`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- sendgrid - elements of list parameters ``to_addresses``, ``cc``, ``bcc``, ``attachments`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- sl_vm - elements of list parameters ``disks``, ``ssh_keys`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- slack - elements of list parameters ``attachments`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- statusio_maintenance - elements of list parameters ``components``, ``containers`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- timezone - add Gentoo and Alpine Linux support (https://github.com/ansible-collections/community.general/issues/781).
|
||||
- twilio - elements of list parameters ``to_numbers`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- vmadm - elements of list parameters ``disks``, ``nics``, ``resolvers``, ``filesystems`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- xfconf - added option ``disable_facts`` to disable facts and its associated deprecation warning (https://github.com/ansible-collections/community.general/issues/1475).
|
||||
- xml - elements of list parameters ``add_children``, ``set_children`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
|
||||
Deprecated Features
|
||||
-------------------
|
||||
|
||||
- xfconf - returning output as facts is deprecated, this will be removed in community.general 4.0.0. Please register the task output in a variable and use it instead. You can already switch to the new behavior now by using the new ``disable_facts`` option (https://github.com/ansible-collections/community.general/pull/1747).
|
||||
|
||||
Bugfixes
|
||||
--------
|
||||
|
||||
- aerospike_migration - fix typo that caused ``migrate_tx_key`` instead of ``migrate_rx_key`` being used (https://github.com/ansible-collections/community.general/pull/1739).
|
||||
- alternatives - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).
|
||||
- beadm - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).
|
||||
- cronvar - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).
|
||||
- dconf - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).
|
||||
- elasticsearch_plugin - ``state`` parameter choices must use ``list()`` in python3 (https://github.com/ansible-collections/community.general/pull/1830).
|
||||
- filesystem - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).
|
||||
- filesystem - remove ``swap`` from list of FS supported by ``resizefs=yes`` (https://github.com/ansible-collections/community.general/issues/790).
|
||||
- git_config - prevent ``run_command`` from expanding values (https://github.com/ansible-collections/community.general/issues/1776).
|
||||
- gitlab_runner - parameter ``registration_token`` was required but is used only when ``state`` is ``present`` (https://github.com/ansible-collections/community.general/issues/1714).
|
||||
- hipchat - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).
|
||||
- interfaces_file - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).
|
||||
- iso_extract - use proper alias deprecation mechanism for ``thirsty`` alias of ``force`` (https://github.com/ansible-collections/community.general/pull/1830).
|
||||
- java_cert - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).
|
||||
- kibana_plugin - ``state`` parameter choices must use ``list()`` in python3 (https://github.com/ansible-collections/community.general/pull/1830).
|
||||
- logstash_plugin - wrapped ``dict.keys()`` with ``list`` for use in ``choices`` setting (https://github.com/ansible-collections/community.general/pull/1830).
|
||||
- lvg - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).
|
||||
- lvol - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).
|
||||
- lxc - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).
|
||||
- lxc_container - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).
|
||||
- nios_host_record - allow DNS Bypass for views other than default (https://github.com/ansible-collections/community.general/issues/1786).
|
||||
- nomad_job_info - fix module failure when nomad client returns no jobs (https://github.com/ansible-collections/community.general/pull/1721).
|
||||
- parted - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).
|
||||
- proxmox lxc - only add the features flag when module parameter ``features`` is set. Before an empty string was send to proxmox in case the parameter was not used, which required to use ``root@pam`` for module execution (https://github.com/ansible-collections/community.general/pull/1763).
|
||||
- proxmox* modules - refactored some parameter validation code into use of ``env_fallback``, ``required_if``, ``required_together``, ``required_one_of`` (https://github.com/ansible-collections/community.general/pull/1765).
|
||||
- proxmox_kvm - do not add ``args`` if ``proxmox_default_behavior`` is set to no_defaults (https://github.com/ansible-collections/community.general/issues/1641).
|
||||
- proxmox_kvm - stop implicitly adding ``force`` equal to ``false``. Proxmox API requires not implemented parameters otherwise, and assumes ``force`` to be ``false`` by default anyways (https://github.com/ansible-collections/community.general/pull/1783).
|
||||
- redhat_subscription - ``mutually_exclusive`` was referring to parameter alias instead of name (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- riak - parameters ``wait_for_handoffs`` and ``wait_for_ring`` are ``int`` but the default value was ``false`` (https://github.com/ansible-collections/community.general/pull/1830).
|
||||
- rundeck_acl_policy - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).
|
||||
- runit - removed unused code, and passing command as ``list`` instead of ``str`` to ``run_command()`` (https://github.com/ansible-collections/community.general/pull/1830).
|
||||
- selective callback plugin - adjust import so that the plugin also works with ansible-core 2.11 (https://github.com/ansible-collections/community.general/pull/1807).
|
||||
- statusio_maintenance - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).
|
||||
- timezone - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).
|
||||
- zfs_delegate_admin - the elements of ``users``, ``groups`` and ``permissions`` are now enforced to be strings (https://github.com/ansible-collections/community.general/pull/1766).
|
||||
|
||||
New Modules
|
||||
-----------
|
||||
|
||||
Monitoring
|
||||
~~~~~~~~~~
|
||||
|
||||
- statsd - Send metrics to StatsD
|
||||
|
||||
v2.0.1
|
||||
======
|
||||
|
||||
Release Summary
|
||||
---------------
|
||||
|
||||
Bugfix and security bugfix (potential information leaks in multiple modules, CVE-2021-20191) release.
|
||||
|
||||
Major Changes
|
||||
-------------
|
||||
|
||||
- For community.general 3.0.0, the ``ome_device_info``, ``idrac_firmware`` and ``idrac_server_config_profile`` modules will be moved to the `dellemc.openmanage <https://galaxy.ansible.com/dellemc/openmanage>`_ collection.
|
||||
A redirection will be inserted so that users using ansible-base 2.10 or newer do not have to change anything.
|
||||
|
||||
If you use Ansible 2.9 and explicitly use the DellEMC modules mentioned above from this collection, you will need to adjust your playbooks and roles to use FQCNs starting with ``dellemc.openmanage.`` instead of ``community.general.``,
|
||||
for example replace ``community.general.ome_device_info`` in a task by ``dellemc.openmanage.ome_device_info``.
|
||||
|
||||
If you use ansible-base and installed ``community.general`` manually and rely on the DellEMC modules mentioned above, you have to make sure to install the ``dellemc.openmanage`` collection as well.
|
||||
If you are using FQCNs, for example ``community.general.ome_device_info`` instead of ``ome_device_info``, it will continue working, but we still recommend to adjust the FQCNs as well.
|
||||
|
||||
Breaking Changes / Porting Guide
|
||||
--------------------------------
|
||||
|
||||
- utm_proxy_auth_profile - the ``frontend_cookie_secret`` return value now contains a placeholder string instead of the module's ``frontend_cookie_secret`` parameter (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
|
||||
Security Fixes
|
||||
--------------
|
||||
|
||||
- dnsmadeeasy - mark the ``account_key`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- gitlab_runner - mark the ``registration_token`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- hwc_ecs_instance - mark the ``admin_pass`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- ibm_sa_host - mark the ``iscsi_chap_secret`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- keycloak_* modules - mark the ``auth_client_secret`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- keycloak_client - mark the ``registration_access_token`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- librato_annotation - mark the ``api_key`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- logentries_msg - mark the ``token`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- module_utils/_netapp, na_ontap_gather_facts - enabled ``no_log`` for the options ``api_key`` and ``secret_key`` to prevent accidental disclosure (CVE-2021-20191, https://github.com/ansible-collections/community.general/pull/1725).
|
||||
- module_utils/identity/keycloak, keycloak_client, keycloak_clienttemplate, keycloak_group - enabled ``no_log`` for the option ``auth_client_secret`` to prevent accidental disclosure (CVE-2021-20191, https://github.com/ansible-collections/community.general/pull/1725).
|
||||
- nios_nsgroup - mark the ``tsig_key`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- oneandone_firewall_policy, oneandone_load_balancer, oneandone_monitoring_policy, oneandone_private_network, oneandone_public_ip - mark the ``auth_token`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- ovirt - mark the ``instance_key`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- ovirt - mark the ``instance_rootpw`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- pagerduty_alert - mark the ``api_key``, ``service_key`` and ``integration_key`` parameters as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- pagerduty_change - mark the ``integration_key`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- pingdom - mark the ``key`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- pulp_repo - mark the ``feed_client_key`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- rax_clb_ssl - mark the ``private_key`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- redfish_command - mark the ``update_creds.password`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- rollbar_deployment - mark the ``token`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- spotinst_aws_elastigroup - mark the ``multai_token`` and ``token`` parameters as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- stackdriver - mark the ``key`` parameter as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- utm_proxy_auth_profile - enabled ``no_log`` for the option ``frontend_cookie_secret`` to prevent accidental disclosure (CVE-2021-20191, https://github.com/ansible-collections/community.general/pull/1725).
|
||||
- utm_proxy_auth_profile - mark the ``frontend_cookie_secret`` parameter as ``no_log`` to avoid leakage of secrets. This causes the ``utm_proxy_auth_profile`` return value to no longer containing the correct value, but a placeholder (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
|
||||
Bugfixes
|
||||
--------
|
||||
|
||||
- filesystem - do not fail when ``resizefs=yes`` and ``fstype=xfs`` if there is nothing to do, even if the filesystem is not mounted. This only covers systems supporting access to unmounted XFS filesystems. Others will still fail (https://github.com/ansible-collections/community.general/issues/1457, https://github.com/ansible-collections/community.general/pull/1478).
|
||||
- gitlab_user - make updates to the ``isadmin``, ``password`` and ``confirm`` options of an already existing GitLab user work (https://github.com/ansible-collections/community.general/pull/1724).
|
||||
- parted - change the regex that decodes the partition size to better support different formats that parted uses. Change the regex that validates parted's version string (https://github.com/ansible-collections/community.general/pull/1695).
|
||||
- redfish_info module, redfish_utils module utils - add ``Name`` and ``Id`` properties to output of Redfish inventory commands (https://github.com/ansible-collections/community.general/issues/1650).
|
||||
- sensu-silence module - fix json parsing of sensu API responses on Python 3.5 (https://github.com/ansible-collections/community.general/pull/1703).
|
||||
|
||||
v2.0.0
|
||||
======
|
||||
|
||||
@@ -434,6 +755,15 @@ Bugfixes
|
||||
- zfs - fixed ``invalid character '@' in pool name"`` error when working with snapshots on a root zvol (https://github.com/ansible-collections/community.general/issues/932).
|
||||
- zypper - force ``LANG=C`` to as zypper is looking in XML output where attribute could be translated (https://github.com/ansible-collections/community.general/issues/1175).
|
||||
|
||||
New Plugins
|
||||
-----------
|
||||
|
||||
Inventory
|
||||
~~~~~~~~~
|
||||
|
||||
- proxmox - Proxmox inventory source
|
||||
- stackpath_compute - StackPath Edge Computing inventory source
|
||||
|
||||
New Modules
|
||||
-----------
|
||||
|
||||
@@ -443,7 +773,24 @@ Cloud
|
||||
misc
|
||||
^^^^
|
||||
|
||||
- proxmox_domain_info - Retrieve information about one or more Proxmox VE domains
|
||||
- proxmox_group_info - Retrieve information about one or more Proxmox VE groups
|
||||
- proxmox_snap - Snapshot management of instances in Proxmox VE cluster
|
||||
- proxmox_user_info - Retrieve information about one or more Proxmox VE users
|
||||
|
||||
scaleway
|
||||
^^^^^^^^
|
||||
|
||||
- scaleway_database_backup - Scaleway database backups management module
|
||||
|
||||
Clustering
|
||||
~~~~~~~~~~
|
||||
|
||||
nomad
|
||||
^^^^^
|
||||
|
||||
- nomad_job - Launch a Nomad Job
|
||||
- nomad_job_info - Get Nomad Jobs info
|
||||
|
||||
Identity
|
||||
~~~~~~~~
|
||||
@@ -456,6 +803,9 @@ ipa
|
||||
Monitoring
|
||||
~~~~~~~~~~
|
||||
|
||||
- pagerduty_change - Track a code or infrastructure change as a PagerDuty change event
|
||||
- pagerduty_user - Manage a user account on PagerDuty
|
||||
|
||||
datadog
|
||||
^^^^^^^
|
||||
|
||||
@@ -471,8 +821,20 @@ os
|
||||
- rpm_ostree_pkg - Install or uninstall overlay additional packages
|
||||
- yum_versionlock - Locks / unlocks a installed package(s) from being updated by yum package manager
|
||||
|
||||
Source Control
|
||||
~~~~~~~~~~~~~~
|
||||
|
||||
gitlab
|
||||
^^^^^^
|
||||
|
||||
- gitlab_group_members - Manage group members on GitLab Server
|
||||
- gitlab_group_variable - Creates, updates, or deletes GitLab groups variables
|
||||
|
||||
System
|
||||
~~~~~~
|
||||
|
||||
- iptables_state - Save iptables state into a file or restore it from a file
|
||||
- shutdown - Shut down a machine
|
||||
- ssh_config - Manage SSH config for user
|
||||
- sysrc - Manage FreeBSD using sysrc
|
||||
- sysupgrade - Manage OpenBSD system upgrades
|
||||
|
||||
@@ -980,23 +980,567 @@ releases:
|
||||
- description: Manages Datadog downtimes
|
||||
name: datadog_downtime
|
||||
namespace: monitoring.datadog
|
||||
- description: Manage group members on GitLab Server
|
||||
name: gitlab_group_members
|
||||
namespace: source_control.gitlab
|
||||
- description: Creates, updates, or deletes GitLab groups variables
|
||||
name: gitlab_group_variable
|
||||
namespace: source_control.gitlab
|
||||
- description: Manage FreeIPA password policies
|
||||
name: ipa_pwpolicy
|
||||
namespace: identity.ipa
|
||||
- description: Save iptables state into a file or restore it from a file
|
||||
name: iptables_state
|
||||
namespace: system
|
||||
- description: Launch a Nomad Job
|
||||
name: nomad_job
|
||||
namespace: clustering.nomad
|
||||
- description: Get Nomad Jobs info
|
||||
name: nomad_job_info
|
||||
namespace: clustering.nomad
|
||||
- description: Track a code or infrastructure change as a PagerDuty change event
|
||||
name: pagerduty_change
|
||||
namespace: monitoring
|
||||
- description: Manage a user account on PagerDuty
|
||||
name: pagerduty_user
|
||||
namespace: monitoring
|
||||
- description: Retrieve information about one or more Proxmox VE domains
|
||||
name: proxmox_domain_info
|
||||
namespace: cloud.misc
|
||||
- description: Retrieve information about one or more Proxmox VE groups
|
||||
name: proxmox_group_info
|
||||
namespace: cloud.misc
|
||||
- description: Snapshot management of instances in Proxmox VE cluster
|
||||
name: proxmox_snap
|
||||
namespace: cloud.misc
|
||||
- description: Retrieve information about one or more Proxmox VE users
|
||||
name: proxmox_user_info
|
||||
namespace: cloud.misc
|
||||
- description: Install or uninstall overlay additional packages
|
||||
name: rpm_ostree_pkg
|
||||
namespace: packaging.os
|
||||
- description: Scaleway database backups management module
|
||||
name: scaleway_database_backup
|
||||
namespace: cloud.scaleway
|
||||
- description: Shut down a machine
|
||||
name: shutdown
|
||||
namespace: system
|
||||
- description: Manage SSH config for user
|
||||
name: ssh_config
|
||||
namespace: system
|
||||
- description: Manage FreeBSD using sysrc
|
||||
name: sysrc
|
||||
namespace: system
|
||||
- description: Manage OpenBSD system upgrades
|
||||
name: sysupgrade
|
||||
namespace: system
|
||||
- description: Locks / unlocks a installed package(s) from being updated by yum
|
||||
package manager
|
||||
name: yum_versionlock
|
||||
namespace: packaging.os
|
||||
plugins:
|
||||
inventory:
|
||||
- description: Proxmox inventory source
|
||||
name: proxmox
|
||||
namespace: null
|
||||
- description: StackPath Edge Computing inventory source
|
||||
name: stackpath_compute
|
||||
namespace: null
|
||||
release_date: '2021-01-28'
|
||||
2.0.1:
|
||||
changes:
|
||||
breaking_changes:
|
||||
- utm_proxy_auth_profile - the ``frontend_cookie_secret`` return value now contains
|
||||
a placeholder string instead of the module's ``frontend_cookie_secret`` parameter
|
||||
(https://github.com/ansible-collections/community.general/pull/1736).
|
||||
bugfixes:
|
||||
- filesystem - do not fail when ``resizefs=yes`` and ``fstype=xfs`` if there
|
||||
is nothing to do, even if the filesystem is not mounted. This only covers
|
||||
systems supporting access to unmounted XFS filesystems. Others will still
|
||||
fail (https://github.com/ansible-collections/community.general/issues/1457,
|
||||
https://github.com/ansible-collections/community.general/pull/1478).
|
||||
- gitlab_user - make updates to the ``isadmin``, ``password`` and ``confirm``
|
||||
options of an already existing GitLab user work (https://github.com/ansible-collections/community.general/pull/1724).
|
||||
- parted - change the regex that decodes the partition size to better support
|
||||
different formats that parted uses. Change the regex that validates parted's
|
||||
version string (https://github.com/ansible-collections/community.general/pull/1695).
|
||||
- redfish_info module, redfish_utils module utils - add ``Name`` and ``Id``
|
||||
properties to output of Redfish inventory commands (https://github.com/ansible-collections/community.general/issues/1650).
|
||||
- sensu-silence module - fix json parsing of sensu API responses on Python 3.5
|
||||
(https://github.com/ansible-collections/community.general/pull/1703).
|
||||
major_changes:
|
||||
- 'For community.general 3.0.0, the ``ome_device_info``, ``idrac_firmware``
|
||||
and ``idrac_server_config_profile`` modules will be moved to the `dellemc.openmanage
|
||||
<https://galaxy.ansible.com/dellemc/openmanage>`_ collection.
|
||||
|
||||
A redirection will be inserted so that users using ansible-base 2.10 or newer
|
||||
do not have to change anything.
|
||||
|
||||
|
||||
If you use Ansible 2.9 and explicitly use the DellEMC modules mentioned above
|
||||
from this collection, you will need to adjust your playbooks and roles to
|
||||
use FQCNs starting with ``dellemc.openmanage.`` instead of ``community.general.``,
|
||||
|
||||
for example replace ``community.general.ome_device_info`` in a task by ``dellemc.openmanage.ome_device_info``.
|
||||
|
||||
|
||||
If you use ansible-base and installed ``community.general`` manually and rely
|
||||
on the DellEMC modules mentioned above, you have to make sure to install the
|
||||
``dellemc.openmanage`` collection as well.
|
||||
|
||||
If you are using FQCNs, for example ``community.general.ome_device_info``
|
||||
instead of ``ome_device_info``, it will continue working, but we still recommend
|
||||
to adjust the FQCNs as well.
|
||||
|
||||
'
|
||||
release_summary: Bugfix and security bugfix (potential information leaks in
|
||||
multiple modules, CVE-2021-20191) release.
|
||||
security_fixes:
|
||||
- dnsmadeeasy - mark the ``account_key`` parameter as ``no_log`` to avoid leakage
|
||||
of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- gitlab_runner - mark the ``registration_token`` parameter as ``no_log`` to
|
||||
avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- hwc_ecs_instance - mark the ``admin_pass`` parameter as ``no_log`` to avoid
|
||||
leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- ibm_sa_host - mark the ``iscsi_chap_secret`` parameter as ``no_log`` to avoid
|
||||
leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- keycloak_* modules - mark the ``auth_client_secret`` parameter as ``no_log``
|
||||
to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- keycloak_client - mark the ``registration_access_token`` parameter as ``no_log``
|
||||
to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- librato_annotation - mark the ``api_key`` parameter as ``no_log`` to avoid
|
||||
leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- logentries_msg - mark the ``token`` parameter as ``no_log`` to avoid leakage
|
||||
of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- module_utils/_netapp, na_ontap_gather_facts - enabled ``no_log`` for the options
|
||||
``api_key`` and ``secret_key`` to prevent accidental disclosure (CVE-2021-20191,
|
||||
https://github.com/ansible-collections/community.general/pull/1725).
|
||||
- module_utils/identity/keycloak, keycloak_client, keycloak_clienttemplate,
|
||||
keycloak_group - enabled ``no_log`` for the option ``auth_client_secret``
|
||||
to prevent accidental disclosure (CVE-2021-20191, https://github.com/ansible-collections/community.general/pull/1725).
|
||||
- nios_nsgroup - mark the ``tsig_key`` parameter as ``no_log`` to avoid leakage
|
||||
of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- oneandone_firewall_policy, oneandone_load_balancer, oneandone_monitoring_policy,
|
||||
oneandone_private_network, oneandone_public_ip - mark the ``auth_token`` parameter
|
||||
as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- ovirt - mark the ``instance_key`` parameter as ``no_log`` to avoid leakage
|
||||
of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- ovirt - mark the ``instance_rootpw`` parameter as ``no_log`` to avoid leakage
|
||||
of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- pagerduty_alert - mark the ``api_key``, ``service_key`` and ``integration_key``
|
||||
parameters as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- pagerduty_change - mark the ``integration_key`` parameter as ``no_log`` to
|
||||
avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- pingdom - mark the ``key`` parameter as ``no_log`` to avoid leakage of secrets
|
||||
(https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- pulp_repo - mark the ``feed_client_key`` parameter as ``no_log`` to avoid
|
||||
leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- rax_clb_ssl - mark the ``private_key`` parameter as ``no_log`` to avoid leakage
|
||||
of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- redfish_command - mark the ``update_creds.password`` parameter as ``no_log``
|
||||
to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- rollbar_deployment - mark the ``token`` parameter as ``no_log`` to avoid leakage
|
||||
of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- spotinst_aws_elastigroup - mark the ``multai_token`` and ``token`` parameters
|
||||
as ``no_log`` to avoid leakage of secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- stackdriver - mark the ``key`` parameter as ``no_log`` to avoid leakage of
|
||||
secrets (https://github.com/ansible-collections/community.general/pull/1736).
|
||||
- utm_proxy_auth_profile - enabled ``no_log`` for the option ``frontend_cookie_secret``
|
||||
to prevent accidental disclosure (CVE-2021-20191, https://github.com/ansible-collections/community.general/pull/1725).
|
||||
- utm_proxy_auth_profile - mark the ``frontend_cookie_secret`` parameter as
|
||||
``no_log`` to avoid leakage of secrets. This causes the ``utm_proxy_auth_profile``
|
||||
return value to no longer containing the correct value, but a placeholder
|
||||
(https://github.com/ansible-collections/community.general/pull/1736).
|
||||
fragments:
|
||||
- 1478-filesystem-fix-1457-resizefs-idempotency.yml
|
||||
- 1691-add-name-and-id-props-to-redfish-inventory-output.yml
|
||||
- 1695-parted-updatedregex.yaml
|
||||
- 1703-sensu_silence-fix_json_parsing.yml
|
||||
- 1724-various-fixes-for-updating-existing-gitlab-user.yml
|
||||
- 2.0.1.yml
|
||||
- CVE-2021-20191_no_log.yml
|
||||
- dellemc-migration.yml
|
||||
- no_log-fixes.yml
|
||||
release_date: '2021-02-09'
|
||||
2.1.0:
|
||||
changes:
|
||||
bugfixes:
|
||||
- aerospike_migration - fix typo that caused ``migrate_tx_key`` instead of ``migrate_rx_key``
|
||||
being used (https://github.com/ansible-collections/community.general/pull/1739).
|
||||
- 'alternatives - internal refactoring: replaced uses of ``_`` with ``dummy``
|
||||
(https://github.com/ansible-collections/community.general/pull/1819).'
|
||||
- 'beadm - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).'
|
||||
- 'cronvar - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).'
|
||||
- 'dconf - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).'
|
||||
- elasticsearch_plugin - ``state`` parameter choices must use ``list()`` in
|
||||
python3 (https://github.com/ansible-collections/community.general/pull/1830).
|
||||
- 'filesystem - internal refactoring: replaced uses of ``_`` with ``dummy``
|
||||
(https://github.com/ansible-collections/community.general/pull/1819).'
|
||||
- filesystem - remove ``swap`` from list of FS supported by ``resizefs=yes``
|
||||
(https://github.com/ansible-collections/community.general/issues/790).
|
||||
- git_config - prevent ``run_command`` from expanding values (https://github.com/ansible-collections/community.general/issues/1776).
|
||||
- gitlab_runner - parameter ``registration_token`` was required but is used
|
||||
only when ``state`` is ``present`` (https://github.com/ansible-collections/community.general/issues/1714).
|
||||
- 'hipchat - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).'
|
||||
- 'interfaces_file - internal refactoring: replaced uses of ``_`` with ``dummy``
|
||||
(https://github.com/ansible-collections/community.general/pull/1819).'
|
||||
- iso_extract - use proper alias deprecation mechanism for ``thirsty`` alias
|
||||
of ``force`` (https://github.com/ansible-collections/community.general/pull/1830).
|
||||
- 'java_cert - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).'
|
||||
- kibana_plugin - ``state`` parameter choices must use ``list()`` in python3
|
||||
(https://github.com/ansible-collections/community.general/pull/1830).
|
||||
- logstash_plugin - wrapped ``dict.keys()`` with ``list`` for use in ``choices``
|
||||
setting (https://github.com/ansible-collections/community.general/pull/1830).
|
||||
- 'lvg - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).'
|
||||
- 'lvol - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).'
|
||||
- 'lxc - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).'
|
||||
- 'lxc_container - internal refactoring: replaced uses of ``_`` with ``dummy``
|
||||
(https://github.com/ansible-collections/community.general/pull/1819).'
|
||||
- nios_host_record - allow DNS Bypass for views other than default (https://github.com/ansible-collections/community.general/issues/1786).
|
||||
- nomad_job_info - fix module failure when nomad client returns no jobs (https://github.com/ansible-collections/community.general/pull/1721).
|
||||
- 'parted - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).'
|
||||
- proxmox lxc - only add the features flag when module parameter ``features``
|
||||
is set. Before an empty string was send to proxmox in case the parameter was
|
||||
not used, which required to use ``root@pam`` for module execution (https://github.com/ansible-collections/community.general/pull/1763).
|
||||
- proxmox* modules - refactored some parameter validation code into use of ``env_fallback``,
|
||||
``required_if``, ``required_together``, ``required_one_of`` (https://github.com/ansible-collections/community.general/pull/1765).
|
||||
- proxmox_kvm - do not add ``args`` if ``proxmox_default_behavior`` is set to
|
||||
no_defaults (https://github.com/ansible-collections/community.general/issues/1641).
|
||||
- proxmox_kvm - stop implicitly adding ``force`` equal to ``false``. Proxmox
|
||||
API requires not implemented parameters otherwise, and assumes ``force`` to
|
||||
be ``false`` by default anyways (https://github.com/ansible-collections/community.general/pull/1783).
|
||||
- redhat_subscription - ``mutually_exclusive`` was referring to parameter alias
|
||||
instead of name (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- riak - parameters ``wait_for_handoffs`` and ``wait_for_ring`` are ``int``
|
||||
but the default value was ``false`` (https://github.com/ansible-collections/community.general/pull/1830).
|
||||
- 'rundeck_acl_policy - internal refactoring: replaced uses of ``_`` with ``dummy``
|
||||
(https://github.com/ansible-collections/community.general/pull/1819).'
|
||||
- runit - removed unused code, and passing command as ``list`` instead of ``str``
|
||||
to ``run_command()`` (https://github.com/ansible-collections/community.general/pull/1830).
|
||||
- selective callback plugin - adjust import so that the plugin also works with
|
||||
ansible-core 2.11 (https://github.com/ansible-collections/community.general/pull/1807).
|
||||
- 'statusio_maintenance - internal refactoring: replaced uses of ``_`` with
|
||||
``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).'
|
||||
- 'timezone - internal refactoring: replaced uses of ``_`` with ``dummy`` (https://github.com/ansible-collections/community.general/pull/1819).'
|
||||
- zfs_delegate_admin - the elements of ``users``, ``groups`` and ``permissions``
|
||||
are now enforced to be strings (https://github.com/ansible-collections/community.general/pull/1766).
|
||||
deprecated_features:
|
||||
- xfconf - returning output as facts is deprecated, this will be removed in
|
||||
community.general 4.0.0. Please register the task output in a variable and
|
||||
use it instead. You can already switch to the new behavior now by using the
|
||||
new ``disable_facts`` option (https://github.com/ansible-collections/community.general/pull/1747).
|
||||
minor_changes:
|
||||
- clc_* modules - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1771).
|
||||
- datadog_monitor - add missing monitor types ``query alert``, ``trace-analytics
|
||||
alert``, ``rum alert`` (https://github.com/ansible-collections/community.general/pull/1723).
|
||||
- dnsimple - add CAA records to the whitelist of valid record types (https://github.com/ansible-collections/community.general/pull/1814).
|
||||
- dnsimple - elements of list parameters ``record_ids`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- gitlab_runner - elements of list parameters ``tag_list`` are now validated
|
||||
(https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- homebrew_tap - add support to specify search path for ``brew`` executable
|
||||
(https://github.com/ansible-collections/community.general/issues/1702).
|
||||
- keycloak_client - elements of list parameters ``default_roles``, ``redirect_uris``,
|
||||
``web_origins`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- librato_annotation - elements of list parameters ``links`` are now validated
|
||||
(https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- lxd_container - ``client_key`` and ``client_cert`` are now of type ``path``
|
||||
and no longer ``str``. A side effect is that certain expansions are made,
|
||||
like ``~`` is replaced by the user's home directory, and environment variables
|
||||
like ``$HOME`` or ``$TEMP`` are evaluated (https://github.com/ansible-collections/community.general/pull/1741).
|
||||
- lxd_container - elements of list parameter ``profiles`` are now validated
|
||||
(https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- lxd_profile - ``client_key`` and ``client_cert`` are now of type ``path``
|
||||
and no longer ``str``. A side effect is that certain expansions are made,
|
||||
like ``~`` is replaced by the user's home directory, and environment variables
|
||||
like ``$HOME`` or ``$TEMP`` are evaluated (https://github.com/ansible-collections/community.general/pull/1741).
|
||||
- lxd_profile - added ``merge_profile`` parameter to merge configurations from
|
||||
the play to an existing profile (https://github.com/ansible-collections/community.general/pull/1813).
|
||||
- mail - elements of list parameters ``to``, ``cc``, ``bcc``, ``attach``, ``headers``
|
||||
are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- na_ontap_gather_facts - elements of list parameters ``gather_subset`` are
|
||||
now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- nexmo - elements of list parameters ``dest`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- nsupdate - elements of list parameters ``value`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- oci_vcn - ``api_user_key_file`` is now of type ``path`` and no longer ``str``.
|
||||
A side effect is that certain expansions are made, like ``~`` is replaced
|
||||
by the user's home directory, and environment variables like ``$HOME`` or
|
||||
``$TEMP`` are evaluated (https://github.com/ansible-collections/community.general/pull/1741).
|
||||
- omapi_host - elements of list parameters ``statements`` are now validated
|
||||
(https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- onepassword_info - elements of list parameters ``search_terms`` are now validated
|
||||
(https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- packet_device - elements of list parameters ``device_ids``, ``hostnames``
|
||||
are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- pagerduty - elements of list parameters ``service`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- plugins/module_utils/oracle/oci_utils.py - elements of list parameter ``key_by``
|
||||
are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- proxmox_kvm module - actually implemented ``vmid`` and ``status`` return values.
|
||||
Updated documentation to reflect current situation (https://github.com/ansible-collections/community.general/issues/1410,
|
||||
https://github.com/ansible-collections/community.general/pull/1715).
|
||||
- pubnub_blocks - elements of list parameters ``event_handlers`` are now validated
|
||||
(https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- redfish modules - explicitly setting lists' elements to ``str`` (https://github.com/ansible-collections/community.general/pull/1761).
|
||||
- redfish_config - case insensitive search for situations where the hostname/FQDN
|
||||
case on iLO doesn't match variable's case (https://github.com/ansible-collections/community.general/pull/1744).
|
||||
- redhat_subscription - elements of list parameters ``pool_ids``, ``addons``
|
||||
are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- rocketchat - elements of list parameters ``attachments`` are now validated
|
||||
(https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- sendgrid - elements of list parameters ``to_addresses``, ``cc``, ``bcc``,
|
||||
``attachments`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- sl_vm - elements of list parameters ``disks``, ``ssh_keys`` are now validated
|
||||
(https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- slack - elements of list parameters ``attachments`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- statusio_maintenance - elements of list parameters ``components``, ``containers``
|
||||
are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- timezone - add Gentoo and Alpine Linux support (https://github.com/ansible-collections/community.general/issues/781).
|
||||
- twilio - elements of list parameters ``to_numbers`` are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- vmadm - elements of list parameters ``disks``, ``nics``, ``resolvers``, ``filesystems``
|
||||
are now validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
- xfconf - added option ``disable_facts`` to disable facts and its associated
|
||||
deprecation warning (https://github.com/ansible-collections/community.general/issues/1475).
|
||||
- xml - elements of list parameters ``add_children``, ``set_children`` are now
|
||||
validated (https://github.com/ansible-collections/community.general/pull/1795).
|
||||
release_summary: Regular feature and bugfix release.
|
||||
fragments:
|
||||
- 1475-xfconf-facts.yml
|
||||
- 1702_homebrew_tap.yml
|
||||
- 1714-gitlab_runner-required-reg-token.yml
|
||||
- 1715-proxmox_kvm-add-vmid-to-returns.yml
|
||||
- 1721-fix-nomad_job_info-no-jobs-failure.yml
|
||||
- 1722_timezone.yml
|
||||
- 1723-datadog_monitor-add-missing-monitor-types.yml
|
||||
- 1740-aerospike_migration.yml
|
||||
- 1741-use-path-argspec.yml
|
||||
- 1744-case-insensitive-hostname-fqdn-matching.yml
|
||||
- 1753-document-fstypes-supported-by-resizefs.yml
|
||||
- 1761-redfish-tidy-up-validation.yml
|
||||
- 1765-proxmox-params.yml
|
||||
- 1766-zfs-fixed-sanity.yml
|
||||
- 1771-centurylink-validation-elements.yml
|
||||
- 1776-git_config-tilde_value.yml
|
||||
- 1783-proxmox-kvm-fix-args-500-error.yaml
|
||||
- 1788-ease-nios_host_record-dns-bypass-check.yml
|
||||
- 1795-list-elements-batch1.yml
|
||||
- 1813-lxd_profile-merge-profiles.yml
|
||||
- 1814-dnsimple-add-support-for-caa-records.yml
|
||||
- 1819-tidyup-pylint-blacklistnames.yml
|
||||
- 1830-valmod_docmissingtype_batch1.yml
|
||||
- 2.1.0.yml
|
||||
- 816-only-invocate-feature-when-variable-is-set.yml
|
||||
- selective-core-2.11.yml
|
||||
modules:
|
||||
- description: Send metrics to StatsD
|
||||
name: statsd
|
||||
namespace: monitoring
|
||||
release_date: '2021-02-16'
|
||||
2.1.1:
|
||||
changes:
|
||||
bugfixes:
|
||||
- proxmox_kvm - fix undefined local variable ``status`` when the parameter ``state``
|
||||
is either ``stopped``, ``started``, ``restarted`` or ``absent`` (https://github.com/ansible-collections/community.general/pull/1847).
|
||||
release_summary: Extraordinary bugfix release to fix a fatal bug in ``proxmox_kvm``.
|
||||
fragments:
|
||||
- 1847-proxmox-kvm-fix-status.yml
|
||||
- 2.1.0.yml
|
||||
release_date: '2021-02-17'
|
||||
2.2.0:
|
||||
changes:
|
||||
bugfixes:
|
||||
- bigpanda - actually use the ``deployment_message`` option (https://github.com/ansible-collections/community.general/pull/1928).
|
||||
- chef_databag lookup plugin - wrapped usages of ``dict.keys()`` in ``list()``
|
||||
for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- cloudforms inventory - fixed issue that non-existing (archived) VMs were synced
|
||||
(https://github.com/ansible-collections/community.general/pull/720).
|
||||
- cobbler_sync, cobbler_system - fix SSL/TLS certificate check when ``validate_certs``
|
||||
set to ``false`` (https://github.com/ansible-collections/community.general/pull/1880).
|
||||
- consul_io inventory script - kv_groups - fix byte chain decoding for Python
|
||||
3 (https://github.com/ansible-collections/community.general/pull/620).
|
||||
- deploy_helper - allow ``state=clean`` to be used without defining a ``release``
|
||||
(https://github.com/ansible-collections/community.general/issues/1852).
|
||||
- diy callback plugin - wrapped usages of ``dict.keys()`` in ``list()`` for
|
||||
Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- idrac_redfish_command - wrapped usages of ``dict.keys()`` in ``list()`` for
|
||||
Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- idrac_redfish_config - wrapped usages of ``dict.keys()`` in ``list()`` for
|
||||
Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- idrac_redfish_info - wrapped usages of ``dict.keys()`` in ``list()`` for Python
|
||||
3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- imc_rest - explicitly logging out instead of registering the call in ```atexit```
|
||||
(https://github.com/ansible-collections/community.general/issues/1735).
|
||||
- infoblox inventory script - make sure that the script also works with Ansible
|
||||
2.9, and returns a more helpful error when community.general is not installed
|
||||
as part of Ansible 2.10/3 (https://github.com/ansible-collections/community.general/pull/1871).
|
||||
- ini_file - allows an empty string as a value for an option (https://github.com/ansible-collections/community.general/pull/1972).
|
||||
- lxc_container - wrapped usages of ``dict.keys()`` in ``list()`` for Python
|
||||
3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- lxd_container - wrapped usages of ``dict.keys()`` in ``list()`` for Python
|
||||
3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- manageiq_provider - wrapped ``dict.keys()`` with ``list`` for use in ``choices``
|
||||
setting (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- memcached cache plugin - wrapped usages of ``dict.keys()`` in ``list()`` for
|
||||
Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- meta/runtime.yml - improve deprecation messages (https://github.com/ansible-collections/community.general/pull/1918).
|
||||
- net_tools.nios.api module_utils - wrapped usages of ``dict.keys()`` in ``list()``
|
||||
for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- nmcli - add ``method4`` and ``method6`` options (https://github.com/ansible-collections/community.general/pull/1894).
|
||||
- nmcli - ensure the ``slave-type`` option is passed to ``nmcli`` for type ``bond-slave``
|
||||
(https://github.com/ansible-collections/community.general/pull/1882).
|
||||
- nsot inventory script - wrapped usages of ``dict.keys()`` in ``list()`` for
|
||||
Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- oci_vcn - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility
|
||||
(https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- oneandone_monitoring_policy - wrapped usages of ``dict.keys()`` in ``list()``
|
||||
for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- packet_volume_attachment - removed extraneous ``print`` call - old debug?
|
||||
(https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- proxmox inventory - added handling of extra trailing slashes in the URL (https://github.com/ansible-collections/community.general/pull/1914).
|
||||
- proxmox_kvm - fix parameter ``vmid`` passed twice to ``exit_json`` while creating
|
||||
a virtual machine without cloning (https://github.com/ansible-collections/community.general/issues/1875,
|
||||
https://github.com/ansible-collections/community.general/pull/1895).
|
||||
- redfish_command - wrapped usages of ``dict.keys()`` in ``list()`` for Python
|
||||
3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- redfish_config - wrapped usages of ``dict.keys()`` in ``list()`` for Python
|
||||
3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- redhat_subscription - wrapped usages of ``dict.keys()`` in ``list()`` for
|
||||
Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- redis cache plugin - wrapped usages of ``keys()`` in ``list()`` for Python
|
||||
3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- selective callback plugin - wrapped usages of ``dict.keys()`` in ``list()``
|
||||
for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- sensu_check - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3
|
||||
compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- spotinst_aws_elastigroup - wrapped usages of ``dict.keys()`` in ``list()``
|
||||
for Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- utm_utils module_utils - wrapped usages of ``dict.keys()`` in ``list()`` for
|
||||
Python 3 compatibility (https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- vdo - wrapped usages of ``dict.keys()`` in ``list()`` for Python 3 compatibility
|
||||
(https://github.com/ansible-collections/community.general/pull/1861).
|
||||
- xfs_quota - the feedback for initializing project quota using xfs_quota binary
|
||||
from ``xfsprogs`` has changed since the version it was written for (https://github.com/ansible-collections/community.general/pull/1596).
|
||||
- zfs - some ZFS properties could be passed when the dataset/volume did not
|
||||
exist, but would fail if the dataset already existed, even if the property
|
||||
matched what was specified in the ansible task (https://github.com/ansible-collections/community.general/issues/868,
|
||||
https://github.com/ansible-collections/community.general/pull/1833).
|
||||
deprecated_features:
|
||||
- apt_rpm - deprecated invalid parameter alias ``update-cache``, will be removed
|
||||
in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- composer - deprecated invalid parameter aliases ``working-dir``, ``global-command``,
|
||||
``prefer-source``, ``prefer-dist``, ``no-dev``, ``no-scripts``, ``no-plugins``,
|
||||
``optimize-autoloader``, ``classmap-authoritative``, ``apcu-autoloader``,
|
||||
``ignore-platform-reqs``, will be removed in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- github_deploy_key - deprecated invalid parameter alias ``2fa_token``, will
|
||||
be removed in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- grove - the option ``message`` will be removed in community.general 4.0.0.
|
||||
Use the new option ``message_content`` instead (https://github.com/ansible-collections/community.general/pull/1929).
|
||||
- homebrew - deprecated invalid parameter alias ``update-brew``, will be removed
|
||||
in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- homebrew_cask - deprecated invalid parameter alias ``update-brew``, will be
|
||||
removed in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- opkg - deprecated invalid parameter alias ``update-cache``, will be removed
|
||||
in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- pacman - deprecated invalid parameter alias ``update-cache``, will be removed
|
||||
in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- puppet - deprecated undocumented parameter ``show_diff``, will be removed
|
||||
in 7.0.0. (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- runit - unused parameter ``dist`` marked for deprecation (https://github.com/ansible-collections/community.general/pull/1830).
|
||||
- slackpkg - deprecated invalid parameter alias ``update-cache``, will be removed
|
||||
in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- urmpi - deprecated invalid parameter aliases ``update-cache`` and ``no-recommends``,
|
||||
will be removed in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
- xbps - deprecated invalid parameter alias ``update-cache``, will be removed
|
||||
in 5.0.0 (https://github.com/ansible-collections/community.general/pull/1927).
|
||||
minor_changes:
|
||||
- bundler - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- consul - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- consul_acl - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- consul_io inventory script - conf options - allow custom configuration options
|
||||
via env variables (https://github.com/ansible-collections/community.general/pull/620).
|
||||
- consul_session - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- datadog_monitor - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- grove - the option ``message`` has been renamed to ``message_content``. The
|
||||
old name ``message`` is kept as an alias and will be removed for community.general
|
||||
4.0.0. This was done because ``message`` is used internally by Ansible (https://github.com/ansible-collections/community.general/pull/1929).
|
||||
- heroku_collaborator - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- linode_v4 - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- manageiq_alert_profiles - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- manageiq_policies - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- manageiq_tags - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- manageiq_tags and manageiq_policies - added new parameter ``resource_id``.
|
||||
This parameter can be used instead of parameter ``resource_name`` (https://github.com/ansible-collections/community.general/pull/719).
|
||||
- module_helper module utils - ``CmdMixin.run_command()`` now accepts ``dict``
|
||||
command arguments, providing the parameter and its value (https://github.com/ansible-collections/community.general/pull/1867).
|
||||
- one_host - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- one_image_info - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- one_vm - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- oneandone_firewall_policy - elements of list parameters are now validated
|
||||
(https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- oneandone_load_balancer - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- oneandone_monitoring_policy - elements of list parameters are now validated
|
||||
(https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- oneandone_private_network - elements of list parameters are now validated
|
||||
(https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- oneandone_server - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- oneview_datacenter_info - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- oneview_enclosure_info - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- oneview_ethernet_network_info - elements of list parameters are now validated
|
||||
(https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- oneview_network_set_info - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- profitbricks - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- profitbricks_volume - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- scaleway_compute - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- scaleway_lb - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1970).
|
||||
- sensu_check - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- sensu_client - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- sensu_handler - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- webfaction_domain - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- webfaction_site - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/1885).
|
||||
- yum_versionlock - Do the lock/unlock concurrently to speed up (https://github.com/ansible-collections/community.general/pull/1912).
|
||||
release_summary: Regular feature and bugfix release.
|
||||
fragments:
|
||||
- 1596-xfs_quota-feedback_on_projects_not_initialized_has_changed.yml
|
||||
- 1735-imc-sessions.yml
|
||||
- 1833-zfs-creation-only-properties.yaml
|
||||
- 1838-runit-deprecate-param-dist.yml
|
||||
- 1852-deploy-helper-fix-state-is-clean-without-release.yaml
|
||||
- 1861-python3-keys.yml
|
||||
- 1867-modhelper-cmdmixin-dict-params.yml
|
||||
- 1871-infoblox-inventory.yml
|
||||
- 1880-fix_cobbler_system_ssl.yml
|
||||
- 1882-fix-nmcli-ensure-slave-type-for-bond-slave.yml
|
||||
- 1885-sanity-check-fixes-batch3.yml
|
||||
- 1894-feat-nmcli-add-method4-and-method6.yml
|
||||
- 1895-proxmox-kvm-fix-issue-1875.yml
|
||||
- 1912-yum_versionlock-lock_unlock_concurrently.yml
|
||||
- 1914-add-sanitization-to-url.yml
|
||||
- 1916-add-version-sort-filter.yml
|
||||
- 1927-removed-parameter-invalid.yml
|
||||
- 1928-bigpanda-message.yml
|
||||
- 1929-grove-message.yml
|
||||
- 1970-valmod-batch7.yml
|
||||
- 1972-ini_file-empty-str-value.yml
|
||||
- 2.2.0.yml
|
||||
- 620-consul_io-env-variables-conf-based.yml
|
||||
- 719-manageiq-resource_id.yml
|
||||
- 720-cloudforms_inventory.yml
|
||||
- meta-runtime-deprecations.yml
|
||||
modules:
|
||||
- description: Manage your repositories on Github
|
||||
name: github_repo
|
||||
namespace: source_control.github
|
||||
- description: Manage project members on GitLab Server
|
||||
name: gitlab_project_members
|
||||
namespace: source_control.gitlab
|
||||
- description: Manage jenkins builds
|
||||
name: jenkins_build
|
||||
namespace: web_infrastructure
|
||||
- description: Retrieve information about one or more Proxmox VE storages
|
||||
name: proxmox_storage_info
|
||||
namespace: cloud.misc
|
||||
plugins:
|
||||
filter:
|
||||
- description: Sort a list according to version order instead of pure alphabetical
|
||||
one
|
||||
name: version_sort
|
||||
namespace: null
|
||||
release_date: '2021-03-08'
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
namespace: community
|
||||
name: general
|
||||
version: 2.0.0
|
||||
version: 2.2.0
|
||||
readme: README.md
|
||||
authors:
|
||||
- Ansible (https://github.com/ansible)
|
||||
|
||||
120
meta/runtime.yml
120
meta/runtime.yml
@@ -41,7 +41,7 @@ plugin_routing:
|
||||
ali_instance_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.ali_instance_info instead.
|
||||
docker_compose:
|
||||
redirect: community.docker.docker_compose
|
||||
docker_config:
|
||||
@@ -198,15 +198,15 @@ plugin_routing:
|
||||
hpilo_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.hpilo_info instead.
|
||||
idrac_redfish_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.idrac_redfish_info instead.
|
||||
jenkins_job_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.jenkins_job_info instead.
|
||||
katello:
|
||||
tombstone:
|
||||
removal_version: 2.0.0
|
||||
@@ -226,7 +226,7 @@ plugin_routing:
|
||||
ldap_attr:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.ldap_attrs instead.
|
||||
logicmonitor:
|
||||
tombstone:
|
||||
removal_version: 1.0.0
|
||||
@@ -238,11 +238,11 @@ plugin_routing:
|
||||
memset_memstore_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.memset_memstore_info instead.
|
||||
memset_server_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.memset_server_info instead.
|
||||
na_cdot_aggregate:
|
||||
tombstone:
|
||||
removal_version: 2.0.0
|
||||
@@ -278,159 +278,159 @@ plugin_routing:
|
||||
na_ontap_gather_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use netapp.ontap.na_ontap_info instead.
|
||||
nginx_status_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.nginx_status_info instead.
|
||||
one_image_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.one_image_info instead.
|
||||
onepassword_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.onepassword_info instead.
|
||||
oneview_datacenter_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.oneview_datacenter_info instead.
|
||||
oneview_enclosure_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.oneview_enclosure_info instead.
|
||||
oneview_ethernet_network_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.oneview_ethernet_network_info instead.
|
||||
oneview_fc_network_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.oneview_fc_network_info instead.
|
||||
oneview_fcoe_network_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.oneview_fcoe_network_info instead.
|
||||
oneview_logical_interconnect_group_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.oneview_logical_interconnect_group_info instead.
|
||||
oneview_network_set_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.oneview_network_set_info instead.
|
||||
oneview_san_manager_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.oneview_san_manager_info instead.
|
||||
online_server_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.online_server_info instead.
|
||||
online_user_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.online_user_info instead.
|
||||
ovirt:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_vm instead.
|
||||
ovirt_affinity_label_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_affinity_label_info instead.
|
||||
ovirt_api_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_api_info instead.
|
||||
ovirt_cluster_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_cluster_info instead.
|
||||
ovirt_datacenter_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_datacenter_info instead.
|
||||
ovirt_disk_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_disk_info instead.
|
||||
ovirt_event_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_event_info instead.
|
||||
ovirt_external_provider_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_external_provider_info instead.
|
||||
ovirt_group_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_group_info instead.
|
||||
ovirt_host_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_host_info instead.
|
||||
ovirt_host_storage_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_host_storage_info instead.
|
||||
ovirt_network_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_network_info instead.
|
||||
ovirt_nic_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_nic_info instead.
|
||||
ovirt_permission_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_permission_info instead.
|
||||
ovirt_quota_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_quota_info instead.
|
||||
ovirt_scheduling_policy_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_scheduling_policy_info instead.
|
||||
ovirt_snapshot_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_snapshot_info instead.
|
||||
ovirt_storage_domain_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_storage_domain_info instead.
|
||||
ovirt_storage_template_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_storage_template_info instead.
|
||||
ovirt_storage_vm_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_storage_vm_info instead.
|
||||
ovirt_tag_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_tag_info instead.
|
||||
ovirt_template_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_template_info instead.
|
||||
ovirt_user_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_user_info instead.
|
||||
ovirt_vm_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_vm_info instead.
|
||||
ovirt_vmpool_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use ovirt.ovirt.ovirt_vmpool_info instead.
|
||||
postgresql_copy:
|
||||
redirect: community.postgresql.postgresql_copy
|
||||
postgresql_db:
|
||||
@@ -478,47 +478,47 @@ plugin_routing:
|
||||
purefa_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use purestorage.flasharray.purefa_info instead.
|
||||
purefb_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use purestorage.flashblade.purefb_info instead.
|
||||
python_requirements_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.python_requirements_info instead.
|
||||
redfish_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.redfish_info instead.
|
||||
scaleway_image_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.scaleway_image_info instead.
|
||||
scaleway_ip_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.scaleway_ip_info instead.
|
||||
scaleway_organization_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.scaleway_organization_info instead.
|
||||
scaleway_security_group_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.scaleway_security_group_info instead.
|
||||
scaleway_server_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.scaleway_server_info instead.
|
||||
scaleway_snapshot_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.scaleway_snapshot_info instead.
|
||||
scaleway_volume_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.scaleway_volume_info instead.
|
||||
sf_account_manager:
|
||||
tombstone:
|
||||
removal_version: 2.0.0
|
||||
@@ -542,15 +542,15 @@ plugin_routing:
|
||||
smartos_image_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.smartos_image_info instead.
|
||||
vertica_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.vertica_info instead.
|
||||
xenserver_guest_facts:
|
||||
deprecation:
|
||||
removal_version: 3.0.0
|
||||
warning_text: see plugin documentation for details
|
||||
warning_text: Use community.general.xenserver_guest_info instead.
|
||||
doc_fragments:
|
||||
_gcp:
|
||||
redirect: community.google._gcp
|
||||
|
||||
2
plugins/cache/memcached.py
vendored
2
plugins/cache/memcached.py
vendored
@@ -162,7 +162,7 @@ class CacheModuleKeys(MutableSet):
|
||||
self._cache.set(self.PREFIX, self._keyset)
|
||||
|
||||
def remove_by_timerange(self, s_min, s_max):
|
||||
for k in self._keyset.keys():
|
||||
for k in list(self._keyset.keys()):
|
||||
t = self._keyset[k]
|
||||
if s_min < t < s_max:
|
||||
del self._keyset[k]
|
||||
|
||||
6
plugins/cache/redis.py
vendored
6
plugins/cache/redis.py
vendored
@@ -217,14 +217,12 @@ class CacheModule(BaseCacheModule):
|
||||
self._db.zrem(self._keys_set, key)
|
||||
|
||||
def flush(self):
|
||||
for key in self.keys():
|
||||
for key in list(self.keys()):
|
||||
self.delete(key)
|
||||
|
||||
def copy(self):
|
||||
# TODO: there is probably a better way to do this in redis
|
||||
ret = dict()
|
||||
for key in self.keys():
|
||||
ret[key] = self.get(key)
|
||||
ret = dict([(k, self.get(k)) for k in self.keys()])
|
||||
return ret
|
||||
|
||||
def __getstate__(self):
|
||||
|
||||
@@ -1013,7 +1013,7 @@ class CallbackModule(Default):
|
||||
for attr in _stats_attributes:
|
||||
_ret[self.DIY_NS]['stats'].update({attr: _get_value(obj=stats, attr=attr)})
|
||||
|
||||
_ret[self.DIY_NS].update({'top_level_var_names': _ret.keys()})
|
||||
_ret[self.DIY_NS].update({'top_level_var_names': list(_ret.keys())})
|
||||
|
||||
return _ret
|
||||
|
||||
|
||||
@@ -173,8 +173,7 @@ class CallbackModule(CallbackBase):
|
||||
# Displays info about playbook being started by a person on an
|
||||
# inventory, as well as Tags, Skip Tags and Limits
|
||||
if not self.printed_playbook:
|
||||
self.playbook_name, _ = os.path.splitext(
|
||||
os.path.basename(self.play.playbook.filename))
|
||||
self.playbook_name, dummy = os.path.splitext(os.path.basename(self.play.playbook.filename))
|
||||
host_list = self.play.playbook.inventory.host_list
|
||||
inventory = os.path.basename(os.path.realpath(host_list))
|
||||
self.send_msg("%s: Playbook initiated by %s against %s" %
|
||||
|
||||
@@ -41,7 +41,16 @@ import difflib
|
||||
from ansible import constants as C
|
||||
from ansible.plugins.callback import CallbackBase
|
||||
from ansible.module_utils._text import to_text
|
||||
from ansible.utils.color import codeCodes
|
||||
|
||||
try:
|
||||
codeCodes = C.COLOR_CODES
|
||||
except AttributeError:
|
||||
# This constant was moved to ansible.constants in
|
||||
# https://github.com/ansible/ansible/commit/1202dd000f10b0e8959019484f1c3b3f9628fc67
|
||||
# (will be included in ansible-core 2.11.0). For older Ansible/ansible-base versions,
|
||||
# we include from the original location.
|
||||
from ansible.utils.color import codeCodes
|
||||
|
||||
|
||||
DONT_COLORIZE = False
|
||||
COLORS = {
|
||||
@@ -58,7 +67,7 @@ COLORS = {
|
||||
|
||||
def dict_diff(prv, nxt):
|
||||
"""Return a dict of keys that differ with another config object."""
|
||||
keys = set(prv.keys() + nxt.keys())
|
||||
keys = set(list(prv.keys()) + list(nxt.keys()))
|
||||
result = {}
|
||||
for k in keys:
|
||||
if prv.get(k) != nxt.get(k):
|
||||
|
||||
@@ -86,7 +86,7 @@ class Connection(ConnectionBase):
|
||||
write_fds = []
|
||||
while len(read_fds) > 0 or len(write_fds) > 0:
|
||||
try:
|
||||
ready_reads, ready_writes, _ = select.select(read_fds, write_fds, [])
|
||||
ready_reads, ready_writes, dummy = select.select(read_fds, write_fds, [])
|
||||
except select.error as e:
|
||||
if e.args[0] == errno.EINTR:
|
||||
continue
|
||||
|
||||
@@ -47,7 +47,7 @@ class ModuleDocFragment(object):
|
||||
OCI_USER_KEY_FILE variable, if any, is used. This option is required if the private key is
|
||||
not specified through a configuration file (See C(config_file_location)). If the key is encrypted
|
||||
with a pass-phrase, the C(api_user_key_pass_phrase) option must also be provided.
|
||||
type: str
|
||||
type: path
|
||||
api_user_key_pass_phrase:
|
||||
description:
|
||||
- Passphrase used by the key referenced in C(api_user_key_file), if it is encrypted. If not set, then
|
||||
|
||||
@@ -20,4 +20,5 @@ class ModuleDocFragment(object):
|
||||
identify an instance of the resource. By default, all the attributes of a resource except
|
||||
I(freeform_tags) are used to uniquely identify a resource.
|
||||
type: list
|
||||
elements: str
|
||||
"""
|
||||
|
||||
21
plugins/filter/version_sort.py
Normal file
21
plugins/filter/version_sort.py
Normal file
@@ -0,0 +1,21 @@
|
||||
# Copyright (C) 2021 Eric Lavarde <elavarde@redhat.com>
|
||||
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
|
||||
|
||||
from __future__ import (absolute_import, division, print_function)
|
||||
__metaclass__ = type
|
||||
|
||||
from distutils.version import LooseVersion
|
||||
|
||||
|
||||
def version_sort(value, reverse=False):
|
||||
'''Sort a list according to loose versions so that e.g. 2.9 is smaller than 2.10'''
|
||||
return sorted(value, key=LooseVersion, reverse=reverse)
|
||||
|
||||
|
||||
class FilterModule(object):
|
||||
''' Version sort filter '''
|
||||
|
||||
def filters(self):
|
||||
return {
|
||||
'version_sort': version_sort
|
||||
}
|
||||
@@ -34,18 +34,15 @@ DOCUMENTATION = r'''
|
||||
description: Populate inventory with instances in this region.
|
||||
default: []
|
||||
type: list
|
||||
required: false
|
||||
tags:
|
||||
description: Populate inventory only with instances which have at least one of the tags listed here.
|
||||
default: []
|
||||
type: list
|
||||
reqired: false
|
||||
version_added: 2.0.0
|
||||
types:
|
||||
description: Populate inventory with instances with this type.
|
||||
default: []
|
||||
type: list
|
||||
required: false
|
||||
strict:
|
||||
version_added: 2.0.0
|
||||
compose:
|
||||
|
||||
@@ -226,10 +226,8 @@ class InventoryModule(BaseInventoryPlugin, Cacheable):
|
||||
if config == 'rootfs' or config.startswith(('virtio', 'sata', 'ide', 'scsi')):
|
||||
value = ('disk_image=' + value)
|
||||
|
||||
if isinstance(value, int) or ',' not in value:
|
||||
value = value
|
||||
# split off strings with commas to a dict
|
||||
else:
|
||||
if not (isinstance(value, int) or ',' not in value):
|
||||
# split off strings with commas to a dict
|
||||
# skip over any keys that cannot be processed
|
||||
try:
|
||||
value = dict(key.split("=") for key in value.split(","))
|
||||
@@ -354,7 +352,7 @@ class InventoryModule(BaseInventoryPlugin, Cacheable):
|
||||
self._read_config_data(path)
|
||||
|
||||
# get connection host
|
||||
self.proxmox_url = self.get_option('url')
|
||||
self.proxmox_url = self.get_option('url').rstrip('/')
|
||||
self.proxmox_user = self.get_option('user')
|
||||
self.proxmox_password = self.get_option('password')
|
||||
self.cache_key = self.get_cache_key(path)
|
||||
|
||||
@@ -216,7 +216,7 @@ class InventoryModule(BaseInventoryPlugin, Constructable, Cacheable):
|
||||
yield host not in v
|
||||
yield True
|
||||
|
||||
return all([found_host for found_host in find_host(host, inventory)])
|
||||
return all(find_host(host, inventory))
|
||||
|
||||
def verify_file(self, path):
|
||||
|
||||
|
||||
@@ -81,7 +81,7 @@ class LookupModule(LookupBase):
|
||||
)
|
||||
if args:
|
||||
raise AnsibleError(
|
||||
"unrecognized arguments to with_sequence: %r" % args.keys()
|
||||
"unrecognized arguments to with_sequence: %r" % list(args.keys())
|
||||
)
|
||||
|
||||
def run(self, terms, variables=None, **kwargs):
|
||||
|
||||
@@ -82,6 +82,27 @@ EXAMPLES = r"""
|
||||
| items2dict(key_name='slug',
|
||||
value_name='itemValue'))['password']
|
||||
}}
|
||||
|
||||
- hosts: localhost
|
||||
vars:
|
||||
secret: >-
|
||||
{{
|
||||
lookup(
|
||||
'community.general.tss',
|
||||
102,
|
||||
base_url='https://secretserver.domain.com/SecretServer/',
|
||||
username='user.name',
|
||||
password='password'
|
||||
)
|
||||
}}
|
||||
tasks:
|
||||
- ansible.builtin.debug:
|
||||
msg: >
|
||||
the password is {{
|
||||
(secret['items']
|
||||
| items2dict(key_name='slug',
|
||||
value_name='itemValue'))['password']
|
||||
}}
|
||||
"""
|
||||
|
||||
from ansible.errors import AnsibleError, AnsibleOptionsError
|
||||
|
||||
@@ -142,8 +142,8 @@ def aws_cvs_host_argument_spec():
|
||||
return dict(
|
||||
api_url=dict(required=True, type='str'),
|
||||
validate_certs=dict(required=False, type='bool', default=True),
|
||||
api_key=dict(required=True, type='str'),
|
||||
secret_key=dict(required=True, type='str')
|
||||
api_key=dict(required=True, type='str', no_log=True),
|
||||
secret_key=dict(required=True, type='str', no_log=True)
|
||||
)
|
||||
|
||||
|
||||
|
||||
@@ -130,7 +130,7 @@ class CloudRetry(object):
|
||||
try:
|
||||
return f(*args, **kwargs)
|
||||
except Exception as e:
|
||||
if isinstance(e, cls.base_class):
|
||||
if isinstance(e, cls.base_class): # pylint: disable=isinstance-second-argument-not-valid-type
|
||||
response_code = cls.status_code_from_exception(e)
|
||||
if cls.found(response_code, catch_extra_error_codes):
|
||||
msg = "{0}: Retrying in {1} seconds...".format(str(e), delay)
|
||||
|
||||
@@ -58,7 +58,7 @@ def keycloak_argument_spec():
|
||||
auth_keycloak_url=dict(type='str', aliases=['url'], required=True),
|
||||
auth_client_id=dict(type='str', default='admin-cli'),
|
||||
auth_realm=dict(type='str', required=True),
|
||||
auth_client_secret=dict(type='str', default=None),
|
||||
auth_client_secret=dict(type='str', default=None, no_log=True),
|
||||
auth_username=dict(type='str', aliases=['username'], required=True),
|
||||
auth_password=dict(type='str', aliases=['password'], required=True, no_log=True),
|
||||
validate_certs=dict(type='bool', default=True)
|
||||
|
||||
@@ -284,7 +284,7 @@ class CmdMixin(object):
|
||||
|
||||
def _calculate_args(self, extra_params=None, params=None):
|
||||
def add_arg_formatted_param(_cmd_args, arg_format, _value):
|
||||
args = [x for x in arg_format.to_text(_value)]
|
||||
args = list(arg_format.to_text(_value))
|
||||
return _cmd_args + args
|
||||
|
||||
def find_format(_param):
|
||||
@@ -296,17 +296,28 @@ class CmdMixin(object):
|
||||
param_list = params if params else self.module.params.keys()
|
||||
|
||||
for param in param_list:
|
||||
if param in self.module.argument_spec:
|
||||
if param not in self.module.params:
|
||||
if isinstance(param, dict):
|
||||
if len(param) != 1:
|
||||
raise ModuleHelperException("run_command parameter as a dict must "
|
||||
"contain only one key: {0}".format(param))
|
||||
_param = list(param.keys())[0]
|
||||
fmt = find_format(_param)
|
||||
value = param[_param]
|
||||
elif isinstance(param, str):
|
||||
if param in self.module.argument_spec:
|
||||
fmt = find_format(param)
|
||||
value = self.module.params[param]
|
||||
elif param in extra_params:
|
||||
fmt = find_format(param)
|
||||
value = extra_params[param]
|
||||
else:
|
||||
self.module.deprecate("Cannot determine value for parameter: {0}. "
|
||||
"From version 4.0.0 onwards this will generate an exception".format(param),
|
||||
version="4.0.0", collection_name="community.general")
|
||||
continue
|
||||
fmt = find_format(param)
|
||||
value = self.module.params[param]
|
||||
|
||||
else:
|
||||
if param not in extra_params:
|
||||
continue
|
||||
fmt = find_format(param)
|
||||
value = extra_params[param]
|
||||
self.cmd_args = cmd_args
|
||||
raise ModuleHelperException("run_command parameter must be either a str or a dict: {0}".format(param))
|
||||
cmd_args = add_arg_formatted_param(cmd_args, fmt, value)
|
||||
|
||||
return cmd_args
|
||||
|
||||
@@ -260,13 +260,10 @@ class WapiModule(WapiBase):
|
||||
else:
|
||||
proposed_object[key] = self.module.params[key]
|
||||
|
||||
# If configure_by_dns is set to False, then delete the default dns set in the param else throw exception
|
||||
# If configure_by_dns is set to False and view is 'default', then delete the default dns
|
||||
if not proposed_object.get('configure_for_dns') and proposed_object.get('view') == 'default'\
|
||||
and ib_obj_type == NIOS_HOST_RECORD:
|
||||
del proposed_object['view']
|
||||
elif not proposed_object.get('configure_for_dns') and proposed_object.get('view') != 'default'\
|
||||
and ib_obj_type == NIOS_HOST_RECORD:
|
||||
self.module.fail_json(msg='DNS Bypass is not allowed if DNS view is set other than \'default\'')
|
||||
|
||||
if ib_obj_ref:
|
||||
if len(ib_obj_ref) > 1:
|
||||
@@ -502,12 +499,12 @@ class WapiModule(WapiBase):
|
||||
else:
|
||||
test_obj_filter = dict([('name', old_name)])
|
||||
# get the object reference
|
||||
ib_obj = self.get_object(ib_obj_type, test_obj_filter, return_fields=ib_spec.keys())
|
||||
ib_obj = self.get_object(ib_obj_type, test_obj_filter, return_fields=list(ib_spec.keys()))
|
||||
if ib_obj:
|
||||
obj_filter['name'] = new_name
|
||||
else:
|
||||
test_obj_filter['name'] = new_name
|
||||
ib_obj = self.get_object(ib_obj_type, test_obj_filter, return_fields=ib_spec.keys())
|
||||
ib_obj = self.get_object(ib_obj_type, test_obj_filter, return_fields=list(ib_spec.keys()))
|
||||
update = True
|
||||
return ib_obj, update, new_name
|
||||
if (ib_obj_type == NIOS_HOST_RECORD):
|
||||
@@ -541,7 +538,7 @@ class WapiModule(WapiBase):
|
||||
# check if test_obj_filter is empty copy passed obj_filter
|
||||
else:
|
||||
test_obj_filter = obj_filter
|
||||
ib_obj = self.get_object(ib_obj_type, test_obj_filter.copy(), return_fields=ib_spec.keys())
|
||||
ib_obj = self.get_object(ib_obj_type, test_obj_filter.copy(), return_fields=list(ib_spec.keys()))
|
||||
elif (ib_obj_type == NIOS_A_RECORD):
|
||||
# resolves issue where multiple a_records with same name and different IP address
|
||||
test_obj_filter = obj_filter
|
||||
@@ -551,7 +548,7 @@ class WapiModule(WapiBase):
|
||||
except TypeError:
|
||||
ipaddr = obj_filter['ipv4addr']
|
||||
test_obj_filter['ipv4addr'] = ipaddr
|
||||
ib_obj = self.get_object(ib_obj_type, test_obj_filter.copy(), return_fields=ib_spec.keys())
|
||||
ib_obj = self.get_object(ib_obj_type, test_obj_filter.copy(), return_fields=list(ib_spec.keys()))
|
||||
elif (ib_obj_type == NIOS_TXT_RECORD):
|
||||
# resolves issue where multiple txt_records with same name and different text
|
||||
test_obj_filter = obj_filter
|
||||
@@ -561,12 +558,12 @@ class WapiModule(WapiBase):
|
||||
except TypeError:
|
||||
txt = obj_filter['text']
|
||||
test_obj_filter['text'] = txt
|
||||
ib_obj = self.get_object(ib_obj_type, test_obj_filter.copy(), return_fields=ib_spec.keys())
|
||||
ib_obj = self.get_object(ib_obj_type, test_obj_filter.copy(), return_fields=list(ib_spec.keys()))
|
||||
elif (ib_obj_type == NIOS_ZONE):
|
||||
# del key 'restart_if_needed' as nios_zone get_object fails with the key present
|
||||
temp = ib_spec['restart_if_needed']
|
||||
del ib_spec['restart_if_needed']
|
||||
ib_obj = self.get_object(ib_obj_type, obj_filter.copy(), return_fields=ib_spec.keys())
|
||||
ib_obj = self.get_object(ib_obj_type, obj_filter.copy(), return_fields=list(ib_spec.keys()))
|
||||
# reinstate restart_if_needed if ib_obj is none, meaning there's no existing nios_zone ref
|
||||
if not ib_obj:
|
||||
ib_spec['restart_if_needed'] = temp
|
||||
@@ -574,12 +571,12 @@ class WapiModule(WapiBase):
|
||||
# del key 'create_token' as nios_member get_object fails with the key present
|
||||
temp = ib_spec['create_token']
|
||||
del ib_spec['create_token']
|
||||
ib_obj = self.get_object(ib_obj_type, obj_filter.copy(), return_fields=ib_spec.keys())
|
||||
ib_obj = self.get_object(ib_obj_type, obj_filter.copy(), return_fields=list(ib_spec.keys()))
|
||||
if temp:
|
||||
# reinstate 'create_token' key
|
||||
ib_spec['create_token'] = temp
|
||||
else:
|
||||
ib_obj = self.get_object(ib_obj_type, obj_filter.copy(), return_fields=ib_spec.keys())
|
||||
ib_obj = self.get_object(ib_obj_type, obj_filter.copy(), return_fields=list(ib_spec.keys()))
|
||||
return ib_obj, update, new_name
|
||||
|
||||
def on_update(self, proposed_object, ib_spec):
|
||||
|
||||
@@ -90,7 +90,7 @@ def get_common_arg_spec(supports_create=False, supports_wait=False):
|
||||
config_profile_name=dict(type="str", default="DEFAULT"),
|
||||
api_user=dict(type="str"),
|
||||
api_user_fingerprint=dict(type="str", no_log=True),
|
||||
api_user_key_file=dict(type="str"),
|
||||
api_user_key_file=dict(type="path"),
|
||||
api_user_key_pass_phrase=dict(type="str", no_log=True),
|
||||
auth_type=dict(
|
||||
type="str",
|
||||
@@ -104,7 +104,7 @@ def get_common_arg_spec(supports_create=False, supports_wait=False):
|
||||
|
||||
if supports_create:
|
||||
common_args.update(
|
||||
key_by=dict(type="list"),
|
||||
key_by=dict(type="list", elements="str"),
|
||||
force_create=dict(type="bool", default=False),
|
||||
)
|
||||
|
||||
|
||||
@@ -469,7 +469,7 @@ class RedfishUtils(object):
|
||||
controller_results = []
|
||||
# Get these entries, but does not fail if not found
|
||||
properties = ['CacheSummary', 'FirmwareVersion', 'Identifiers',
|
||||
'Location', 'Manufacturer', 'Model', 'Name',
|
||||
'Location', 'Manufacturer', 'Model', 'Name', 'Id',
|
||||
'PartNumber', 'SerialNumber', 'SpeedGbps', 'Status']
|
||||
key = "StorageControllers"
|
||||
|
||||
@@ -1700,7 +1700,7 @@ class RedfishUtils(object):
|
||||
chassis_results = []
|
||||
|
||||
# Get these entries, but does not fail if not found
|
||||
properties = ['ChassisType', 'PartNumber', 'AssetTag',
|
||||
properties = ['Name', 'Id', 'ChassisType', 'PartNumber', 'AssetTag',
|
||||
'Manufacturer', 'IndicatorLED', 'SerialNumber', 'Model']
|
||||
|
||||
# Go through list
|
||||
@@ -1724,7 +1724,7 @@ class RedfishUtils(object):
|
||||
fan_results = []
|
||||
key = "Thermal"
|
||||
# Get these entries, but does not fail if not found
|
||||
properties = ['FanName', 'Reading', 'ReadingUnits', 'Status']
|
||||
properties = ['Name', 'FanName', 'Reading', 'ReadingUnits', 'Status']
|
||||
|
||||
# Go through list
|
||||
for chassis_uri in self.chassis_uris:
|
||||
@@ -1836,8 +1836,8 @@ class RedfishUtils(object):
|
||||
cpu_results = []
|
||||
key = "Processors"
|
||||
# Get these entries, but does not fail if not found
|
||||
properties = ['Id', 'Manufacturer', 'Model', 'MaxSpeedMHz', 'TotalCores',
|
||||
'TotalThreads', 'Status']
|
||||
properties = ['Id', 'Name', 'Manufacturer', 'Model', 'MaxSpeedMHz',
|
||||
'TotalCores', 'TotalThreads', 'Status']
|
||||
|
||||
# Search for 'key' entry and extract URI from it
|
||||
response = self.get_request(self.root_uri + systems_uri)
|
||||
@@ -1886,7 +1886,7 @@ class RedfishUtils(object):
|
||||
memory_results = []
|
||||
key = "Memory"
|
||||
# Get these entries, but does not fail if not found
|
||||
properties = ['SerialNumber', 'MemoryDeviceType', 'PartNumber',
|
||||
properties = ['Id', 'SerialNumber', 'MemoryDeviceType', 'PartNumber',
|
||||
'MemoryLocation', 'RankCount', 'CapacityMiB', 'OperatingMemoryModes', 'Status', 'Manufacturer', 'Name']
|
||||
|
||||
# Search for 'key' entry and extract URI from it
|
||||
@@ -1943,7 +1943,7 @@ class RedfishUtils(object):
|
||||
nic_results = []
|
||||
key = "EthernetInterfaces"
|
||||
# Get these entries, but does not fail if not found
|
||||
properties = ['Description', 'FQDN', 'IPv4Addresses', 'IPv6Addresses',
|
||||
properties = ['Name', 'Id', 'Description', 'FQDN', 'IPv4Addresses', 'IPv6Addresses',
|
||||
'NameServers', 'MACAddress', 'PermanentMACAddress',
|
||||
'SpeedMbps', 'MTUSize', 'AutoNeg', 'Status']
|
||||
|
||||
@@ -2368,7 +2368,7 @@ class RedfishUtils(object):
|
||||
properties = ['Status', 'HostName', 'PowerState', 'Model', 'Manufacturer',
|
||||
'PartNumber', 'SystemType', 'AssetTag', 'ServiceTag',
|
||||
'SerialNumber', 'SKU', 'BiosVersion', 'MemorySummary',
|
||||
'ProcessorSummary', 'TrustedModules']
|
||||
'ProcessorSummary', 'TrustedModules', 'Name', 'Id']
|
||||
|
||||
response = self.get_request(self.root_uri + systems_uri)
|
||||
if response['ret'] is False:
|
||||
@@ -2632,7 +2632,7 @@ class RedfishUtils(object):
|
||||
if response['ret'] is False:
|
||||
return response
|
||||
data = response['data']
|
||||
if '"' + nic_addr + '"' in str(data) or "'" + nic_addr + "'" in str(data):
|
||||
if '"' + nic_addr.lower() + '"' in str(data).lower() or "'" + nic_addr.lower() + "'" in str(data).lower():
|
||||
target_ethernet_uri = uri
|
||||
target_ethernet_current_setting = data
|
||||
break
|
||||
|
||||
@@ -84,7 +84,7 @@ class UTM:
|
||||
raise UTMModuleConfigurationError(
|
||||
"The keys " + to_native(
|
||||
self.change_relevant_keys) + " to check are not in the modules keys:\n" + to_native(
|
||||
module.params.keys()))
|
||||
list(module.params.keys())))
|
||||
|
||||
def execute(self):
|
||||
try:
|
||||
|
||||
@@ -32,6 +32,7 @@ options:
|
||||
- A list of recipient email ids to notify the alert.
|
||||
This is required for state 'present'
|
||||
type: list
|
||||
elements: str
|
||||
metric:
|
||||
description:
|
||||
- The metric on which to measure the condition that will trigger the alert.
|
||||
@@ -220,7 +221,7 @@ class ClcAlertPolicy:
|
||||
name=dict(),
|
||||
id=dict(),
|
||||
alias=dict(required=True),
|
||||
alert_recipients=dict(type='list'),
|
||||
alert_recipients=dict(type='list', elements='str'),
|
||||
metric=dict(
|
||||
choices=[
|
||||
'cpu',
|
||||
|
||||
@@ -18,6 +18,7 @@ options:
|
||||
- A list of server Ids to deploy the blue print package.
|
||||
type: list
|
||||
required: True
|
||||
elements: str
|
||||
package_id:
|
||||
description:
|
||||
- The package id of the blue print.
|
||||
@@ -164,7 +165,7 @@ class ClcBlueprintPackage:
|
||||
:return: the package dictionary object
|
||||
"""
|
||||
argument_spec = dict(
|
||||
server_ids=dict(type='list', required=True),
|
||||
server_ids=dict(type='list', elements='str', required=True),
|
||||
package_id=dict(required=True),
|
||||
package_params=dict(type='dict', default={}),
|
||||
wait=dict(default=True), # @FIXME should be bool?
|
||||
|
||||
@@ -29,17 +29,20 @@ options:
|
||||
- The list of source addresses for traffic on the originating firewall.
|
||||
This is required when state is 'present'
|
||||
type: list
|
||||
elements: str
|
||||
destination:
|
||||
description:
|
||||
- The list of destination addresses for traffic on the terminating firewall.
|
||||
This is required when state is 'present'
|
||||
type: list
|
||||
elements: str
|
||||
ports:
|
||||
description:
|
||||
- The list of ports associated with the policy.
|
||||
TCP and UDP can take in single ports or port ranges.
|
||||
- "Example: C(['any', 'icmp', 'TCP/123', 'UDP/123', 'TCP/123-456', 'UDP/123-456'])."
|
||||
type: list
|
||||
elements: str
|
||||
firewall_policy_id:
|
||||
description:
|
||||
- Id of the firewall policy. This is required to update or delete an existing firewall policy
|
||||
@@ -217,9 +220,9 @@ class ClcFirewallPolicy:
|
||||
source_account_alias=dict(required=True),
|
||||
destination_account_alias=dict(),
|
||||
firewall_policy_id=dict(),
|
||||
ports=dict(type='list'),
|
||||
source=dict(type='list'),
|
||||
destination=dict(type='list'),
|
||||
ports=dict(type='list', elements='str'),
|
||||
source=dict(type='list', elements='str'),
|
||||
destination=dict(type='list', elements='str'),
|
||||
wait=dict(default=True), # @FIXME type=bool
|
||||
state=dict(default='present', choices=['present', 'absent']),
|
||||
enabled=dict(default=True, choices=[True, False])
|
||||
|
||||
@@ -53,6 +53,7 @@ options:
|
||||
- A list of nodes that needs to be added to the load balancer pool
|
||||
type: list
|
||||
default: []
|
||||
elements: dict
|
||||
status:
|
||||
description:
|
||||
- The status of the loadbalancer
|
||||
@@ -869,7 +870,7 @@ class ClcLoadBalancer:
|
||||
port=dict(choices=[80, 443]),
|
||||
method=dict(choices=['leastConnection', 'roundRobin']),
|
||||
persistence=dict(choices=['standard', 'sticky']),
|
||||
nodes=dict(type='list', default=[]),
|
||||
nodes=dict(type='list', default=[], elements='dict'),
|
||||
status=dict(default='enabled', choices=['enabled', 'disabled']),
|
||||
state=dict(
|
||||
default='present',
|
||||
|
||||
@@ -18,6 +18,7 @@ options:
|
||||
- A list of server Ids to modify.
|
||||
type: list
|
||||
required: True
|
||||
elements: str
|
||||
cpu:
|
||||
description:
|
||||
- How many CPUs to update on the server
|
||||
@@ -396,7 +397,7 @@ class ClcModifyServer:
|
||||
:return: argument spec dictionary
|
||||
"""
|
||||
argument_spec = dict(
|
||||
server_ids=dict(type='list', required=True),
|
||||
server_ids=dict(type='list', required=True, elements='str'),
|
||||
state=dict(default='present', choices=['present', 'absent']),
|
||||
cpu=dict(),
|
||||
memory=dict(),
|
||||
|
||||
@@ -23,11 +23,13 @@ options:
|
||||
description:
|
||||
- A list of ports to expose. This is required when state is 'present'
|
||||
type: list
|
||||
elements: int
|
||||
server_ids:
|
||||
description:
|
||||
- A list of servers to create public ips on.
|
||||
type: list
|
||||
required: True
|
||||
elements: str
|
||||
state:
|
||||
description:
|
||||
- Determine whether to create or delete public IPs. If present module will not create a second public ip if one
|
||||
@@ -193,9 +195,9 @@ class ClcPublicIp(object):
|
||||
:return: argument spec dictionary
|
||||
"""
|
||||
argument_spec = dict(
|
||||
server_ids=dict(type='list', required=True),
|
||||
server_ids=dict(type='list', required=True, elements='str'),
|
||||
protocol=dict(default='TCP', choices=['TCP', 'UDP', 'ICMP']),
|
||||
ports=dict(type='list'),
|
||||
ports=dict(type='list', elements='int'),
|
||||
wait=dict(type='bool', default=True),
|
||||
state=dict(default='present', choices=['present', 'absent']),
|
||||
)
|
||||
|
||||
@@ -17,6 +17,7 @@ options:
|
||||
description:
|
||||
- The list of additional disks for the server
|
||||
type: list
|
||||
elements: dict
|
||||
default: []
|
||||
add_public_ip:
|
||||
description:
|
||||
@@ -66,6 +67,7 @@ options:
|
||||
- The list of custom fields to set on the server.
|
||||
type: list
|
||||
default: []
|
||||
elements: dict
|
||||
description:
|
||||
description:
|
||||
- The description to set for the server.
|
||||
@@ -111,6 +113,7 @@ options:
|
||||
description:
|
||||
- The list of blue print packages to run on the server after its created.
|
||||
type: list
|
||||
elements: dict
|
||||
default: []
|
||||
password:
|
||||
description:
|
||||
@@ -130,6 +133,7 @@ options:
|
||||
description:
|
||||
- A list of ports to allow on the firewall to the servers public ip, if add_public_ip is set to True.
|
||||
type: list
|
||||
elements: dict
|
||||
default: []
|
||||
secondary_dns:
|
||||
description:
|
||||
@@ -141,6 +145,7 @@ options:
|
||||
A list of server Ids to insure are started, stopped, or absent.
|
||||
type: list
|
||||
default: []
|
||||
elements: str
|
||||
source_server_password:
|
||||
description:
|
||||
- The password for the source server if a clone is specified.
|
||||
@@ -575,8 +580,8 @@ class ClcServer:
|
||||
type=dict(default='standard', choices=['standard', 'hyperscale', 'bareMetal']),
|
||||
primary_dns=dict(default=None),
|
||||
secondary_dns=dict(default=None),
|
||||
additional_disks=dict(type='list', default=[]),
|
||||
custom_fields=dict(type='list', default=[]),
|
||||
additional_disks=dict(type='list', default=[], elements='dict'),
|
||||
custom_fields=dict(type='list', default=[], elements='dict'),
|
||||
ttl=dict(default=None),
|
||||
managed_os=dict(type='bool', default=False),
|
||||
description=dict(default=None),
|
||||
@@ -586,7 +591,7 @@ class ClcServer:
|
||||
anti_affinity_policy_name=dict(default=None),
|
||||
alert_policy_id=dict(default=None),
|
||||
alert_policy_name=dict(default=None),
|
||||
packages=dict(type='list', default=[]),
|
||||
packages=dict(type='list', default=[], elements='dict'),
|
||||
state=dict(
|
||||
default='present',
|
||||
choices=[
|
||||
@@ -597,7 +602,7 @@ class ClcServer:
|
||||
count=dict(type='int', default=1),
|
||||
exact_count=dict(type='int', default=None),
|
||||
count_group=dict(),
|
||||
server_ids=dict(type='list', default=[]),
|
||||
server_ids=dict(type='list', default=[], elements='str'),
|
||||
add_public_ip=dict(type='bool', default=False),
|
||||
public_ip_protocol=dict(
|
||||
default='TCP',
|
||||
@@ -605,7 +610,7 @@ class ClcServer:
|
||||
'TCP',
|
||||
'UDP',
|
||||
'ICMP']),
|
||||
public_ip_ports=dict(type='list', default=[]),
|
||||
public_ip_ports=dict(type='list', default=[], elements='dict'),
|
||||
configuration_id=dict(default=None),
|
||||
os_type=dict(default=None,
|
||||
choices=[
|
||||
|
||||
@@ -18,6 +18,7 @@ options:
|
||||
- The list of CLC server Ids.
|
||||
type: list
|
||||
required: True
|
||||
elements: str
|
||||
expiration_days:
|
||||
description:
|
||||
- The number of days to keep the server snapshot before it expires.
|
||||
@@ -330,7 +331,7 @@ class ClcSnapshot:
|
||||
:return: the package dictionary object
|
||||
"""
|
||||
argument_spec = dict(
|
||||
server_ids=dict(type='list', required=True),
|
||||
server_ids=dict(type='list', required=True, elements='str'),
|
||||
expiration_days=dict(default=7, type='int'),
|
||||
wait=dict(default=True),
|
||||
state=dict(
|
||||
|
||||
@@ -26,6 +26,7 @@ options:
|
||||
- Heroku API key
|
||||
apps:
|
||||
type: list
|
||||
elements: str
|
||||
description:
|
||||
- List of Heroku App names
|
||||
required: true
|
||||
@@ -109,7 +110,7 @@ def main():
|
||||
argument_spec = HerokuHelper.heroku_argument_spec()
|
||||
argument_spec.update(
|
||||
user=dict(required=True, type='str'),
|
||||
apps=dict(required=True, type='list'),
|
||||
apps=dict(required=True, type='list', elements='str'),
|
||||
suppress_invitation=dict(default=False, type='bool'),
|
||||
state=dict(default='present', type='str', choices=['present', 'absent']),
|
||||
)
|
||||
|
||||
@@ -543,7 +543,7 @@ def build_module():
|
||||
snapshot_id=dict(type='str')
|
||||
)),
|
||||
vpc_id=dict(type='str', required=True),
|
||||
admin_pass=dict(type='str'),
|
||||
admin_pass=dict(type='str', no_log=True),
|
||||
data_volumes=dict(type='list', elements='dict', options=dict(
|
||||
volume_id=dict(type='str', required=True),
|
||||
device=dict(type='str')
|
||||
|
||||
@@ -63,6 +63,7 @@ options:
|
||||
U(https://www.linode.com/docs/api/tags/).
|
||||
required: false
|
||||
type: list
|
||||
elements: str
|
||||
root_pass:
|
||||
description:
|
||||
- The password for the root user. If not specified, one will be
|
||||
@@ -75,6 +76,7 @@ options:
|
||||
- A list of SSH public key parts to deploy for the root user.
|
||||
required: false
|
||||
type: list
|
||||
elements: str
|
||||
state:
|
||||
description:
|
||||
- The desired instance state.
|
||||
@@ -240,12 +242,12 @@ def initialise_module():
|
||||
no_log=True,
|
||||
fallback=(env_fallback, ['LINODE_ACCESS_TOKEN']),
|
||||
),
|
||||
authorized_keys=dict(type='list', required=False),
|
||||
authorized_keys=dict(type='list', elements='str', required=False),
|
||||
group=dict(type='str', required=False),
|
||||
image=dict(type='str', required=False),
|
||||
region=dict(type='str', required=False),
|
||||
root_pass=dict(type='str', required=False, no_log=True),
|
||||
tags=dict(type='list', required=False),
|
||||
tags=dict(type='list', elements='str', required=False),
|
||||
type=dict(type='str', required=False),
|
||||
stackscript_id=dict(type='int', required=False),
|
||||
stackscript_data=dict(type='dict', required=False),
|
||||
|
||||
@@ -730,7 +730,7 @@ class LxcContainerManagement(object):
|
||||
for option_line in container_config:
|
||||
# Look for key in config
|
||||
if keyre.match(option_line):
|
||||
_, _value = option_line.split('=', 1)
|
||||
dummy, _value = option_line.split('=', 1)
|
||||
config_value = ' '.join(_value.split())
|
||||
line_index = container_config.index(option_line)
|
||||
# If the sanitized values don't match replace them
|
||||
@@ -953,7 +953,7 @@ class LxcContainerManagement(object):
|
||||
"""
|
||||
|
||||
self.container = self.get_container_bind()
|
||||
for _ in xrange(timeout):
|
||||
for dummy in xrange(timeout):
|
||||
if self._get_state() != 'running':
|
||||
self.container.start()
|
||||
self.state_change = True
|
||||
@@ -1006,7 +1006,7 @@ class LxcContainerManagement(object):
|
||||
:type timeout: ``int``
|
||||
"""
|
||||
|
||||
for _ in xrange(timeout):
|
||||
for dummy in xrange(timeout):
|
||||
if not self._container_exists(container_name=self.container_name, lxc_path=self.lxc_path):
|
||||
break
|
||||
|
||||
@@ -1662,7 +1662,7 @@ def main():
|
||||
),
|
||||
backing_store=dict(
|
||||
type='str',
|
||||
choices=LXC_BACKING_STORE.keys(),
|
||||
choices=list(LXC_BACKING_STORE.keys()),
|
||||
default='dir'
|
||||
),
|
||||
template_options=dict(
|
||||
@@ -1699,7 +1699,7 @@ def main():
|
||||
type='path'
|
||||
),
|
||||
state=dict(
|
||||
choices=LXC_ANSIBLE_STATES.keys(),
|
||||
choices=list(LXC_ANSIBLE_STATES.keys()),
|
||||
default='started'
|
||||
),
|
||||
container_command=dict(
|
||||
@@ -1733,7 +1733,7 @@ def main():
|
||||
type='path',
|
||||
),
|
||||
archive_compression=dict(
|
||||
choices=LXC_COMPRESSION_MAP.keys(),
|
||||
choices=list(LXC_COMPRESSION_MAP.keys()),
|
||||
default='gzip'
|
||||
)
|
||||
),
|
||||
|
||||
@@ -45,6 +45,7 @@ options:
|
||||
description:
|
||||
- Profile to be used by the container
|
||||
type: list
|
||||
elements: str
|
||||
devices:
|
||||
description:
|
||||
- 'The devices for the container
|
||||
@@ -132,14 +133,14 @@ options:
|
||||
- If not specified, it defaults to C(${HOME}/.config/lxc/client.key).
|
||||
required: false
|
||||
aliases: [ key_file ]
|
||||
type: str
|
||||
type: path
|
||||
client_cert:
|
||||
description:
|
||||
- The client certificate file path.
|
||||
- If not specified, it defaults to C(${HOME}/.config/lxc/client.crt).
|
||||
required: false
|
||||
aliases: [ cert_file ]
|
||||
type: str
|
||||
type: path
|
||||
trust_password:
|
||||
description:
|
||||
- The client trusted password.
|
||||
@@ -658,12 +659,13 @@ def main():
|
||||
),
|
||||
profiles=dict(
|
||||
type='list',
|
||||
elements='str',
|
||||
),
|
||||
source=dict(
|
||||
type='dict',
|
||||
),
|
||||
state=dict(
|
||||
choices=LXD_ANSIBLE_STATES.keys(),
|
||||
choices=list(LXD_ANSIBLE_STATES.keys()),
|
||||
default='started'
|
||||
),
|
||||
target=dict(
|
||||
@@ -690,11 +692,11 @@ def main():
|
||||
default='unix:/var/snap/lxd/common/lxd/unix.socket'
|
||||
),
|
||||
client_key=dict(
|
||||
type='str',
|
||||
type='path',
|
||||
aliases=['key_file']
|
||||
),
|
||||
client_cert=dict(
|
||||
type='str',
|
||||
type='path',
|
||||
aliases=['cert_file']
|
||||
),
|
||||
trust_password=dict(type='str', no_log=True)
|
||||
|
||||
@@ -2,12 +2,12 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# Copyright: (c) 2016, Hiroaki Nakamura <hnakamur@gmail.com>
|
||||
# Copyright: (c) 2020, Frank Dornheim <dornheim@posteo.de>
|
||||
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
|
||||
|
||||
from __future__ import absolute_import, division, print_function
|
||||
__metaclass__ = type
|
||||
|
||||
|
||||
DOCUMENTATION = '''
|
||||
---
|
||||
module: lxd_profile
|
||||
@@ -52,6 +52,14 @@ options:
|
||||
See U(https://github.com/lxc/lxd/blob/master/doc/rest-api.md#post-11)
|
||||
required: false
|
||||
type: str
|
||||
merge_profile:
|
||||
description:
|
||||
- Merge the configuration of the present profile with the new desired configuration,
|
||||
instead of replacing it.
|
||||
required: false
|
||||
default: false
|
||||
type: bool
|
||||
version_added: 2.1.0
|
||||
state:
|
||||
choices:
|
||||
- present
|
||||
@@ -79,14 +87,14 @@ options:
|
||||
- If not specified, it defaults to C($HOME/.config/lxc/client.key).
|
||||
required: false
|
||||
aliases: [ key_file ]
|
||||
type: str
|
||||
type: path
|
||||
client_cert:
|
||||
description:
|
||||
- The client certificate file path.
|
||||
- If not specified, it defaults to C($HOME/.config/lxc/client.crt).
|
||||
required: false
|
||||
aliases: [ cert_file ]
|
||||
type: str
|
||||
type: path
|
||||
trust_password:
|
||||
description:
|
||||
- The client trusted password.
|
||||
@@ -142,6 +150,23 @@ EXAMPLES = '''
|
||||
parent: br0
|
||||
type: nic
|
||||
|
||||
# An example for modify/merge a profile
|
||||
- hosts: localhost
|
||||
connection: local
|
||||
tasks:
|
||||
- name: Merge a profile
|
||||
community.general.lxd_profile:
|
||||
merge_profile: true
|
||||
name: macvlan
|
||||
state: present
|
||||
config: {}
|
||||
description: my macvlan profile
|
||||
devices:
|
||||
eth0:
|
||||
nictype: macvlan
|
||||
parent: br0
|
||||
type: nic
|
||||
|
||||
# An example for deleting a profile
|
||||
- hosts: localhost
|
||||
connection: local
|
||||
@@ -181,7 +206,6 @@ actions:
|
||||
'''
|
||||
|
||||
import os
|
||||
|
||||
from ansible.module_utils.basic import AnsibleModule
|
||||
from ansible_collections.community.general.plugins.module_utils.lxd import LXDClient, LXDClientException
|
||||
|
||||
@@ -266,7 +290,7 @@ class LXDProfileManagement(object):
|
||||
self._create_profile()
|
||||
else:
|
||||
self.module.fail_json(
|
||||
msg='new_name must not be set when the profile does not exist and the specified state is present',
|
||||
msg='new_name must not be set when the profile does not exist and the state is present',
|
||||
changed=False)
|
||||
else:
|
||||
if self.new_name is not None and self.new_name != self.name:
|
||||
@@ -307,10 +331,96 @@ class LXDProfileManagement(object):
|
||||
self._needs_to_change_profile_config('devices')
|
||||
)
|
||||
|
||||
def _apply_profile_configs(self):
|
||||
config = self.old_profile_json.copy()
|
||||
def _merge_dicts(self, source, destination):
|
||||
"""Merge Dictionarys
|
||||
|
||||
Get a list of filehandle numbers from logger to be handed to
|
||||
DaemonContext.files_preserve
|
||||
|
||||
Args:
|
||||
dict(source): source dict
|
||||
dict(destination): destination dict
|
||||
Kwargs:
|
||||
None
|
||||
Raises:
|
||||
None
|
||||
Returns:
|
||||
dict(destination): merged dict"""
|
||||
for key, value in source.items():
|
||||
if isinstance(value, dict):
|
||||
# get node or create one
|
||||
node = destination.setdefault(key, {})
|
||||
self._merge_dicts(value, node)
|
||||
else:
|
||||
destination[key] = value
|
||||
return destination
|
||||
|
||||
def _merge_config(self, config):
|
||||
""" merge profile
|
||||
|
||||
Merge Configuration of the present profile and the new desired configitems
|
||||
|
||||
Args:
|
||||
dict(config): Dict with the old config in 'metadata' and new config in 'config'
|
||||
Kwargs:
|
||||
None
|
||||
Raises:
|
||||
None
|
||||
Returns:
|
||||
dict(config): new config"""
|
||||
# merge or copy the sections from the existing profile to 'config'
|
||||
for item in ['config', 'description', 'devices', 'name', 'used_by']:
|
||||
if item in config:
|
||||
config[item] = self._merge_dicts(config['metadata'][item], config[item])
|
||||
else:
|
||||
config[item] = config['metadata'][item]
|
||||
# merge or copy the sections from the ansible-task to 'config'
|
||||
return self._merge_dicts(self.config, config)
|
||||
|
||||
def _generate_new_config(self, config):
|
||||
""" rebuild profile
|
||||
|
||||
Rebuild the Profile by the configuration provided in the play.
|
||||
Existing configurations are discarded.
|
||||
|
||||
This ist the default behavior.
|
||||
|
||||
Args:
|
||||
dict(config): Dict with the old config in 'metadata' and new config in 'config'
|
||||
Kwargs:
|
||||
None
|
||||
Raises:
|
||||
None
|
||||
Returns:
|
||||
dict(config): new config"""
|
||||
for k, v in self.config.items():
|
||||
config[k] = v
|
||||
return config
|
||||
|
||||
def _apply_profile_configs(self):
|
||||
""" Selection of the procedure: rebuild or merge
|
||||
|
||||
The standard behavior is that all information not contained
|
||||
in the play is discarded.
|
||||
|
||||
If "merge_profile" is provides in the play and "True", then existing
|
||||
configurations from the profile and new ones defined are merged.
|
||||
|
||||
Args:
|
||||
None
|
||||
Kwargs:
|
||||
None
|
||||
Raises:
|
||||
None
|
||||
Returns:
|
||||
None"""
|
||||
config = self.old_profile_json.copy()
|
||||
if self.module.params['merge_profile']:
|
||||
config = self._merge_config(config)
|
||||
else:
|
||||
config = self._generate_new_config(config)
|
||||
|
||||
# upload config to lxd
|
||||
self.client.do('PUT', '/1.0/profiles/{0}'.format(self.name), config)
|
||||
self.actions.append('apply_profile_configs')
|
||||
|
||||
@@ -371,6 +481,10 @@ def main():
|
||||
devices=dict(
|
||||
type='dict',
|
||||
),
|
||||
merge_profile=dict(
|
||||
type='bool',
|
||||
default=False
|
||||
),
|
||||
state=dict(
|
||||
choices=PROFILES_STATES,
|
||||
default='present'
|
||||
@@ -384,11 +498,11 @@ def main():
|
||||
default='unix:/var/snap/lxd/common/lxd/unix.socket'
|
||||
),
|
||||
client_key=dict(
|
||||
type='str',
|
||||
type='path',
|
||||
aliases=['key_file']
|
||||
),
|
||||
client_cert=dict(
|
||||
type='str',
|
||||
type='path',
|
||||
aliases=['cert_file']
|
||||
),
|
||||
trust_password=dict(type='str', no_log=True)
|
||||
|
||||
@@ -405,8 +405,8 @@ def main():
|
||||
instance_gateway=dict(type='str', aliases=['gateway']),
|
||||
instance_domain=dict(type='str', aliases=['domain']),
|
||||
instance_dns=dict(type='str', aliases=['dns']),
|
||||
instance_rootpw=dict(type='str', aliases=['rootpw']),
|
||||
instance_key=dict(type='str', aliases=['key']),
|
||||
instance_rootpw=dict(type='str', aliases=['rootpw'], no_log=True),
|
||||
instance_key=dict(type='str', aliases=['key'], no_log=True),
|
||||
sdomain=dict(type='str'),
|
||||
region=dict(type='str'),
|
||||
),
|
||||
|
||||
@@ -345,7 +345,6 @@ EXAMPLES = r'''
|
||||
state: absent
|
||||
'''
|
||||
|
||||
import os
|
||||
import time
|
||||
import traceback
|
||||
from distutils.version import LooseVersion
|
||||
@@ -356,7 +355,7 @@ try:
|
||||
except ImportError:
|
||||
HAS_PROXMOXER = False
|
||||
|
||||
from ansible.module_utils.basic import AnsibleModule
|
||||
from ansible.module_utils.basic import AnsibleModule, env_fallback
|
||||
from ansible.module_utils._text import to_native
|
||||
|
||||
|
||||
@@ -481,7 +480,7 @@ def main():
|
||||
module = AnsibleModule(
|
||||
argument_spec=dict(
|
||||
api_host=dict(required=True),
|
||||
api_password=dict(no_log=True),
|
||||
api_password=dict(no_log=True, fallback=(env_fallback, ['PROXMOX_PASSWORD'])),
|
||||
api_token_id=dict(no_log=True),
|
||||
api_token_secret=dict(no_log=True),
|
||||
api_user=dict(required=True),
|
||||
@@ -514,7 +513,10 @@ def main():
|
||||
description=dict(type='str'),
|
||||
hookscript=dict(type='str'),
|
||||
proxmox_default_behavior=dict(type='str', choices=['compatibility', 'no_defaults']),
|
||||
)
|
||||
),
|
||||
required_if=[('state', 'present', ['node', 'hostname', 'password', 'ostemplate'])],
|
||||
required_together=[('api_token_id', 'api_token_secret')],
|
||||
required_one_of=[('api_password', 'api_token_id')],
|
||||
)
|
||||
|
||||
if not HAS_PROXMOXER:
|
||||
@@ -561,13 +563,7 @@ def main():
|
||||
module.params[param] = value
|
||||
|
||||
auth_args = {'user': api_user}
|
||||
if not (api_token_id and api_token_secret):
|
||||
# If password not set get it from PROXMOX_PASSWORD env
|
||||
if not api_password:
|
||||
try:
|
||||
api_password = os.environ['PROXMOX_PASSWORD']
|
||||
except KeyError as e:
|
||||
module.fail_json(msg='You should set api_password param or use PROXMOX_PASSWORD environment variable')
|
||||
if not api_token_id:
|
||||
auth_args['password'] = api_password
|
||||
else:
|
||||
auth_args['token_name'] = api_token_id
|
||||
@@ -599,8 +595,6 @@ def main():
|
||||
# If no vmid was passed, there cannot be another VM named 'hostname'
|
||||
if not module.params['vmid'] and get_vmid(proxmox, hostname) and not module.params['force']:
|
||||
module.exit_json(changed=False, msg="VM with hostname %s already exists and has ID number %s" % (hostname, get_vmid(proxmox, hostname)[0]))
|
||||
elif not (node, module.params['hostname'] and module.params['password'] and module.params['ostemplate']):
|
||||
module.fail_json(msg='node, hostname, password and ostemplate are mandatory for creating vm')
|
||||
elif not node_check(proxmox, node):
|
||||
module.fail_json(msg="node '%s' not exists in cluster" % node)
|
||||
elif not content_check(proxmox, node, module.params['ostemplate'], template_store):
|
||||
@@ -622,7 +616,7 @@ def main():
|
||||
searchdomain=module.params['searchdomain'],
|
||||
force=int(module.params['force']),
|
||||
pubkey=module.params['pubkey'],
|
||||
features=",".join(module.params['features'] or []),
|
||||
features=",".join(module.params['features']) if module.params['features'] is not None else None,
|
||||
unprivileged=int(module.params['unprivileged']),
|
||||
description=module.params['description'],
|
||||
hookscript=module.params['hookscript'])
|
||||
|
||||
@@ -31,6 +31,9 @@ options:
|
||||
description:
|
||||
- Pass arbitrary arguments to kvm.
|
||||
- This option is for experts only!
|
||||
- If I(proxmox_default_behavior) is set to C(compatiblity) (the default value), this
|
||||
option has a default of C(-serial unix:/var/run/qemu-server/<vmid>.serial,server,nowait).
|
||||
Note that the default value of I(proxmox_default_behavior) changes in community.general 4.0.0.
|
||||
type: str
|
||||
autostart:
|
||||
description:
|
||||
@@ -730,46 +733,23 @@ EXAMPLES = '''
|
||||
'''
|
||||
|
||||
RETURN = '''
|
||||
devices:
|
||||
description: The list of devices created or used.
|
||||
returned: success
|
||||
type: dict
|
||||
sample: '
|
||||
{
|
||||
"ide0": "VMS_LVM:vm-115-disk-1",
|
||||
"ide1": "VMs:115/vm-115-disk-3.raw",
|
||||
"virtio0": "VMS_LVM:vm-115-disk-2",
|
||||
"virtio1": "VMs:115/vm-115-disk-1.qcow2",
|
||||
"virtio2": "VMs:115/vm-115-disk-2.raw"
|
||||
}'
|
||||
mac:
|
||||
description: List of mac address created and net[n] attached. Useful when you want to use provision systems like Foreman via PXE.
|
||||
returned: success
|
||||
type: dict
|
||||
sample: '
|
||||
{
|
||||
"net0": "3E:6E:97:D2:31:9F",
|
||||
"net1": "B6:A1:FC:EF:78:A4"
|
||||
}'
|
||||
vmid:
|
||||
description: The VM vmid.
|
||||
returned: success
|
||||
type: int
|
||||
sample: 115
|
||||
description: The VM vmid.
|
||||
returned: success
|
||||
type: int
|
||||
sample: 115
|
||||
status:
|
||||
description:
|
||||
- The current virtual machine status.
|
||||
- Returned only when C(state=current)
|
||||
returned: success
|
||||
type: dict
|
||||
sample: '{
|
||||
"changed": false,
|
||||
"msg": "VM kropta with vmid = 110 is running",
|
||||
"status": "running"
|
||||
}'
|
||||
description: The current virtual machine status.
|
||||
returned: success, not clone, not absent, not update
|
||||
type: str
|
||||
sample: running
|
||||
msg:
|
||||
description: A short message
|
||||
returned: always
|
||||
type: str
|
||||
sample: "VM kropta with vmid = 110 is running"
|
||||
'''
|
||||
|
||||
import os
|
||||
import re
|
||||
import time
|
||||
import traceback
|
||||
@@ -782,7 +762,7 @@ try:
|
||||
except ImportError:
|
||||
HAS_PROXMOXER = False
|
||||
|
||||
from ansible.module_utils.basic import AnsibleModule
|
||||
from ansible.module_utils.basic import AnsibleModule, env_fallback
|
||||
from ansible.module_utils._text import to_native
|
||||
|
||||
|
||||
@@ -948,9 +928,9 @@ def create_vm(module, proxmox, vmid, newid, node, name, memory, cpu, cores, sock
|
||||
if searchdomains:
|
||||
kwargs['searchdomain'] = ' '.join(searchdomains)
|
||||
|
||||
# -args and skiplock require root@pam user
|
||||
# -args and skiplock require root@pam user - but can not use api tokens
|
||||
if module.params['api_user'] == "root@pam" and module.params['args'] is None:
|
||||
if not update:
|
||||
if not update and module.params['proxmox_default_behavior'] == 'compatibility':
|
||||
kwargs['args'] = vm_args
|
||||
elif module.params['api_user'] == "root@pam" and module.params['args'] is not None:
|
||||
kwargs['args'] = module.params['args']
|
||||
@@ -1015,7 +995,7 @@ def main():
|
||||
agent=dict(type='bool'),
|
||||
args=dict(type='str'),
|
||||
api_host=dict(required=True),
|
||||
api_password=dict(no_log=True),
|
||||
api_password=dict(no_log=True, fallback=(env_fallback, ['PROXMOX_PASSWORD'])),
|
||||
api_token_id=dict(no_log=True),
|
||||
api_token_secret=dict(no_log=True),
|
||||
api_user=dict(required=True),
|
||||
@@ -1028,12 +1008,12 @@ def main():
|
||||
cipassword=dict(type='str', no_log=True),
|
||||
citype=dict(type='str', choices=['nocloud', 'configdrive2']),
|
||||
ciuser=dict(type='str'),
|
||||
clone=dict(type='str', default=None),
|
||||
clone=dict(type='str'),
|
||||
cores=dict(type='int'),
|
||||
cpu=dict(type='str'),
|
||||
cpulimit=dict(type='int'),
|
||||
cpuunits=dict(type='int'),
|
||||
delete=dict(type='str', default=None),
|
||||
delete=dict(type='str'),
|
||||
description=dict(type='str'),
|
||||
digest=dict(type='str'),
|
||||
force=dict(type='bool'),
|
||||
@@ -1056,7 +1036,7 @@ def main():
|
||||
name=dict(type='str'),
|
||||
nameservers=dict(type='list', elements='str'),
|
||||
net=dict(type='dict'),
|
||||
newid=dict(type='int', default=None),
|
||||
newid=dict(type='int'),
|
||||
node=dict(),
|
||||
numa=dict(type='dict'),
|
||||
numa_enabled=dict(type='bool'),
|
||||
@@ -1092,13 +1072,14 @@ def main():
|
||||
vcpus=dict(type='int'),
|
||||
vga=dict(choices=['std', 'cirrus', 'vmware', 'qxl', 'serial0', 'serial1', 'serial2', 'serial3', 'qxl2', 'qxl3', 'qxl4']),
|
||||
virtio=dict(type='dict'),
|
||||
vmid=dict(type='int', default=None),
|
||||
vmid=dict(type='int'),
|
||||
watchdog=dict(),
|
||||
proxmox_default_behavior=dict(type='str', choices=['compatibility', 'no_defaults']),
|
||||
),
|
||||
mutually_exclusive=[('delete', 'revert'), ('delete', 'update'), ('revert', 'update'), ('clone', 'update'), ('clone', 'delete'), ('clone', 'revert')],
|
||||
required_one_of=[('name', 'vmid',)],
|
||||
required_if=[('state', 'present', ['node'])]
|
||||
required_together=[('api_token_id', 'api_token_secret')],
|
||||
required_one_of=[('name', 'vmid'), ('api_password', 'api_token_id')],
|
||||
required_if=[('state', 'present', ['node'])],
|
||||
)
|
||||
|
||||
if not HAS_PROXMOXER:
|
||||
@@ -1140,7 +1121,6 @@ def main():
|
||||
cores=1,
|
||||
cpu='kvm64',
|
||||
cpuunits=1000,
|
||||
force=False,
|
||||
format='qcow2',
|
||||
kvm=True,
|
||||
memory=512,
|
||||
@@ -1159,12 +1139,6 @@ def main():
|
||||
|
||||
auth_args = {'user': api_user}
|
||||
if not (api_token_id and api_token_secret):
|
||||
# If password not set get it from PROXMOX_PASSWORD env
|
||||
if not api_password:
|
||||
try:
|
||||
api_password = os.environ['PROXMOX_PASSWORD']
|
||||
except KeyError:
|
||||
module.fail_json(msg='You should set api_password param or use PROXMOX_PASSWORD environment variable')
|
||||
auth_args['password'] = api_password
|
||||
else:
|
||||
auth_args['token_name'] = api_token_id
|
||||
@@ -1207,36 +1181,36 @@ def main():
|
||||
|
||||
# Ensure source VM id exists when cloning
|
||||
if not get_vm(proxmox, vmid):
|
||||
module.fail_json(msg='VM with vmid = %s does not exist in cluster' % vmid)
|
||||
module.fail_json(vmid=vmid, msg='VM with vmid = %s does not exist in cluster' % vmid)
|
||||
|
||||
# Ensure the choosen VM name doesn't already exist when cloning
|
||||
if get_vmid(proxmox, name):
|
||||
module.exit_json(changed=False, msg="VM with name <%s> already exists" % name)
|
||||
module.exit_json(changed=False, vmid=vmid, msg="VM with name <%s> already exists" % name)
|
||||
|
||||
# Ensure the choosen VM id doesn't already exist when cloning
|
||||
if get_vm(proxmox, newid):
|
||||
module.exit_json(changed=False, msg="vmid %s with VM name %s already exists" % (newid, name))
|
||||
module.exit_json(changed=False, vmid=vmid, msg="vmid %s with VM name %s already exists" % (newid, name))
|
||||
|
||||
if delete is not None:
|
||||
try:
|
||||
settings(module, proxmox, vmid, node, name, delete=delete)
|
||||
module.exit_json(changed=True, msg="Settings has deleted on VM {0} with vmid {1}".format(name, vmid))
|
||||
module.exit_json(changed=True, vmid=vmid, msg="Settings has deleted on VM {0} with vmid {1}".format(name, vmid))
|
||||
except Exception as e:
|
||||
module.fail_json(msg='Unable to delete settings on VM {0} with vmid {1}: '.format(name, vmid) + str(e))
|
||||
module.fail_json(vmid=vmid, msg='Unable to delete settings on VM {0} with vmid {1}: '.format(name, vmid) + str(e))
|
||||
|
||||
if revert is not None:
|
||||
try:
|
||||
settings(module, proxmox, vmid, node, name, revert=revert)
|
||||
module.exit_json(changed=True, msg="Settings has reverted on VM {0} with vmid {1}".format(name, vmid))
|
||||
module.exit_json(changed=True, vmid=vmid, msg="Settings has reverted on VM {0} with vmid {1}".format(name, vmid))
|
||||
except Exception as e:
|
||||
module.fail_json(msg='Unable to revert settings on VM {0} with vmid {1}: Maybe is not a pending task... '.format(name, vmid) + str(e))
|
||||
module.fail_json(vmid=vmid, msg='Unable to revert settings on VM {0} with vmid {1}: Maybe is not a pending task... '.format(name, vmid) + str(e))
|
||||
|
||||
if state == 'present':
|
||||
try:
|
||||
if get_vm(proxmox, vmid) and not (update or clone):
|
||||
module.exit_json(changed=False, msg="VM with vmid <%s> already exists" % vmid)
|
||||
module.exit_json(changed=False, vmid=vmid, msg="VM with vmid <%s> already exists" % vmid)
|
||||
elif get_vmid(proxmox, name) and not (update or clone):
|
||||
module.exit_json(changed=False, msg="VM with name <%s> already exists" % name)
|
||||
module.exit_json(changed=False, vmid=vmid, msg="VM with name <%s> already exists" % name)
|
||||
elif not (node, name):
|
||||
module.fail_json(msg='node, name is mandatory for creating/updating vm')
|
||||
elif not node_check(proxmox, node):
|
||||
@@ -1309,85 +1283,93 @@ def main():
|
||||
scsi=module.params['scsi'],
|
||||
virtio=module.params['virtio'])
|
||||
if update:
|
||||
module.exit_json(changed=True, msg="VM %s with vmid %s updated" % (name, vmid))
|
||||
module.exit_json(changed=True, vmid=vmid, msg="VM %s with vmid %s updated" % (name, vmid))
|
||||
elif clone is not None:
|
||||
module.exit_json(changed=True, msg="VM %s with newid %s cloned from vm with vmid %s" % (name, newid, vmid))
|
||||
module.exit_json(changed=True, vmid=vmid, msg="VM %s with newid %s cloned from vm with vmid %s" % (name, newid, vmid))
|
||||
else:
|
||||
module.exit_json(changed=True, msg="VM %s with vmid %s deployed" % (name, vmid), **results)
|
||||
except Exception as e:
|
||||
if update:
|
||||
module.fail_json(msg="Unable to update vm {0} with vmid {1}=".format(name, vmid) + str(e))
|
||||
module.fail_json(vmid=vmid, msg="Unable to update vm {0} with vmid {1}=".format(name, vmid) + str(e))
|
||||
elif clone is not None:
|
||||
module.fail_json(msg="Unable to clone vm {0} from vmid {1}=".format(name, vmid) + str(e))
|
||||
module.fail_json(vmid=vmid, msg="Unable to clone vm {0} from vmid {1}=".format(name, vmid) + str(e))
|
||||
else:
|
||||
module.fail_json(msg="creation of qemu VM %s with vmid %s failed with exception=%s" % (name, vmid, e))
|
||||
module.fail_json(vmid=vmid, msg="creation of qemu VM %s with vmid %s failed with exception=%s" % (name, vmid, e))
|
||||
|
||||
elif state == 'started':
|
||||
status = {}
|
||||
try:
|
||||
if -1 == vmid:
|
||||
module.fail_json(msg='VM with name = %s does not exist in cluster' % name)
|
||||
vm = get_vm(proxmox, vmid)
|
||||
if not vm:
|
||||
module.fail_json(msg='VM with vmid <%s> does not exist in cluster' % vmid)
|
||||
module.fail_json(vmid=vmid, msg='VM with vmid <%s> does not exist in cluster' % vmid)
|
||||
status['status'] = vm[0]['status']
|
||||
if vm[0]['status'] == 'running':
|
||||
module.exit_json(changed=False, msg="VM %s is already running" % vmid)
|
||||
module.exit_json(changed=False, vmid=vmid, msg="VM %s is already running" % vmid, **status)
|
||||
|
||||
if start_vm(module, proxmox, vm):
|
||||
module.exit_json(changed=True, msg="VM %s started" % vmid)
|
||||
module.exit_json(changed=True, vmid=vmid, msg="VM %s started" % vmid, **status)
|
||||
except Exception as e:
|
||||
module.fail_json(msg="starting of VM %s failed with exception: %s" % (vmid, e))
|
||||
module.fail_json(vmid=vmid, msg="starting of VM %s failed with exception: %s" % (vmid, e), **status)
|
||||
|
||||
elif state == 'stopped':
|
||||
status = {}
|
||||
try:
|
||||
if -1 == vmid:
|
||||
module.fail_json(msg='VM with name = %s does not exist in cluster' % name)
|
||||
|
||||
vm = get_vm(proxmox, vmid)
|
||||
if not vm:
|
||||
module.fail_json(msg='VM with vmid = %s does not exist in cluster' % vmid)
|
||||
module.fail_json(vmid=vmid, msg='VM with vmid = %s does not exist in cluster' % vmid)
|
||||
|
||||
status['status'] = vm[0]['status']
|
||||
if vm[0]['status'] == 'stopped':
|
||||
module.exit_json(changed=False, msg="VM %s is already stopped" % vmid)
|
||||
module.exit_json(changed=False, vmid=vmid, msg="VM %s is already stopped" % vmid, **status)
|
||||
|
||||
if stop_vm(module, proxmox, vm, force=module.params['force']):
|
||||
module.exit_json(changed=True, msg="VM %s is shutting down" % vmid)
|
||||
module.exit_json(changed=True, vmid=vmid, msg="VM %s is shutting down" % vmid, **status)
|
||||
except Exception as e:
|
||||
module.fail_json(msg="stopping of VM %s failed with exception: %s" % (vmid, e))
|
||||
module.fail_json(vmid=vmid, msg="stopping of VM %s failed with exception: %s" % (vmid, e), **status)
|
||||
|
||||
elif state == 'restarted':
|
||||
status = {}
|
||||
try:
|
||||
if -1 == vmid:
|
||||
module.fail_json(msg='VM with name = %s does not exist in cluster' % name)
|
||||
|
||||
vm = get_vm(proxmox, vmid)
|
||||
if not vm:
|
||||
module.fail_json(msg='VM with vmid = %s does not exist in cluster' % vmid)
|
||||
module.fail_json(vmid=vmid, msg='VM with vmid = %s does not exist in cluster' % vmid)
|
||||
status['status'] = vm[0]['status']
|
||||
if vm[0]['status'] == 'stopped':
|
||||
module.exit_json(changed=False, msg="VM %s is not running" % vmid)
|
||||
module.exit_json(changed=False, vmid=vmid, msg="VM %s is not running" % vmid, **status)
|
||||
|
||||
if stop_vm(module, proxmox, vm, force=module.params['force']) and start_vm(module, proxmox, vm):
|
||||
module.exit_json(changed=True, msg="VM %s is restarted" % vmid)
|
||||
module.exit_json(changed=True, vmid=vmid, msg="VM %s is restarted" % vmid, **status)
|
||||
except Exception as e:
|
||||
module.fail_json(msg="restarting of VM %s failed with exception: %s" % (vmid, e))
|
||||
module.fail_json(vmid=vmid, msg="restarting of VM %s failed with exception: %s" % (vmid, e), **status)
|
||||
|
||||
elif state == 'absent':
|
||||
status = {}
|
||||
try:
|
||||
vm = get_vm(proxmox, vmid)
|
||||
if not vm:
|
||||
module.exit_json(changed=False)
|
||||
module.exit_json(changed=False, vmid=vmid)
|
||||
|
||||
proxmox_node = proxmox.nodes(vm[0]['node'])
|
||||
status['status'] = vm[0]['status']
|
||||
if vm[0]['status'] == 'running':
|
||||
if module.params['force']:
|
||||
stop_vm(module, proxmox, vm, True)
|
||||
else:
|
||||
module.exit_json(changed=False, msg="VM %s is running. Stop it before deletion or use force=yes." % vmid)
|
||||
module.exit_json(changed=False, vmid=vmid, msg="VM %s is running. Stop it before deletion or use force=yes." % vmid)
|
||||
taskid = proxmox_node.qemu.delete(vmid)
|
||||
if not wait_for_task(module, proxmox, vm[0]['node'], taskid):
|
||||
module.fail_json(msg='Reached timeout while waiting for removing VM. Last line in task before timeout: %s' %
|
||||
proxmox_node.tasks(taskid).log.get()[:1])
|
||||
else:
|
||||
module.exit_json(changed=True, msg="VM %s removed" % vmid)
|
||||
module.exit_json(changed=True, vmid=vmid, msg="VM %s removed" % vmid)
|
||||
except Exception as e:
|
||||
module.fail_json(msg="deletion of VM %s failed with exception: %s" % (vmid, e))
|
||||
|
||||
@@ -1398,10 +1380,12 @@ def main():
|
||||
vm = get_vm(proxmox, vmid)
|
||||
if not vm:
|
||||
module.fail_json(msg='VM with vmid = %s does not exist in cluster' % vmid)
|
||||
if not name:
|
||||
name = vm[0]['name']
|
||||
current = proxmox.nodes(vm[0]['node']).qemu(vmid).status.current.get()['status']
|
||||
status['status'] = current
|
||||
if status:
|
||||
module.exit_json(changed=False, msg="VM %s with vmid = %s is %s" % (name, vmid, current), **status)
|
||||
module.exit_json(changed=False, vmid=vmid, msg="VM %s with vmid = %s is %s" % (name, vmid, current), **status)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
@@ -31,6 +31,7 @@ options:
|
||||
- The password to authenticate with.
|
||||
- You can use PROXMOX_PASSWORD environment variable.
|
||||
type: str
|
||||
required: yes
|
||||
hostname:
|
||||
description:
|
||||
- The instance name.
|
||||
@@ -106,7 +107,6 @@ EXAMPLES = r'''
|
||||
|
||||
RETURN = r'''#'''
|
||||
|
||||
import os
|
||||
import time
|
||||
import traceback
|
||||
|
||||
@@ -118,7 +118,7 @@ except ImportError:
|
||||
PROXMOXER_IMP_ERR = traceback.format_exc()
|
||||
HAS_PROXMOXER = False
|
||||
|
||||
from ansible.module_utils.basic import AnsibleModule, missing_required_lib
|
||||
from ansible.module_utils.basic import AnsibleModule, missing_required_lib, env_fallback
|
||||
from ansible.module_utils._text import to_native
|
||||
|
||||
|
||||
@@ -182,7 +182,7 @@ def main():
|
||||
argument_spec=dict(
|
||||
api_host=dict(required=True),
|
||||
api_user=dict(required=True),
|
||||
api_password=dict(no_log=True),
|
||||
api_password=dict(no_log=True, required=True, fallback=(env_fallback, ['PROXMOX_PASSWORD'])),
|
||||
vmid=dict(required=False),
|
||||
validate_certs=dict(type='bool', default='no'),
|
||||
hostname=dict(),
|
||||
@@ -213,13 +213,6 @@ def main():
|
||||
force = module.params['force']
|
||||
vmstate = module.params['vmstate']
|
||||
|
||||
# If password not set get it from PROXMOX_PASSWORD env
|
||||
if not api_password:
|
||||
try:
|
||||
api_password = os.environ['PROXMOX_PASSWORD']
|
||||
except KeyError as e:
|
||||
module.fail_json(msg='You should set api_password param or use PROXMOX_PASSWORD environment variable' % to_native(e))
|
||||
|
||||
try:
|
||||
proxmox = setup_api(api_host, api_user, api_password, validate_certs)
|
||||
|
||||
|
||||
190
plugins/modules/cloud/misc/proxmox_storage_info.py
Normal file
190
plugins/modules/cloud/misc/proxmox_storage_info.py
Normal file
@@ -0,0 +1,190 @@
|
||||
#!/usr/bin/python
|
||||
# -*- coding: utf-8 -*-
|
||||
#
|
||||
# Copyright: Tristan Le Guern (@Aversiste) <tleguern at bouledef.eu>
|
||||
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
|
||||
|
||||
from __future__ import absolute_import, division, print_function
|
||||
__metaclass__ = type
|
||||
|
||||
|
||||
DOCUMENTATION = '''
|
||||
---
|
||||
module: proxmox_storage_info
|
||||
short_description: Retrieve information about one or more Proxmox VE storages
|
||||
version_added: 2.2.0
|
||||
description:
|
||||
- Retrieve information about one or more Proxmox VE storages.
|
||||
options:
|
||||
storage:
|
||||
description:
|
||||
- Only return informations on a specific storage.
|
||||
aliases: ['name']
|
||||
type: str
|
||||
type:
|
||||
description:
|
||||
- Filter on a specifc storage type.
|
||||
type: str
|
||||
author: Tristan Le Guern (@Aversiste)
|
||||
extends_documentation_fragment: community.general.proxmox.documentation
|
||||
notes:
|
||||
- Storage specific options can be returned by this module, please look at the documentation at U(https://pve.proxmox.com/wiki/Storage).
|
||||
'''
|
||||
|
||||
|
||||
EXAMPLES = '''
|
||||
- name: List existing storages
|
||||
community.general.proxmox_storage_info:
|
||||
api_host: helldorado
|
||||
api_user: root@pam
|
||||
api_password: "{{ password | default(omit) }}"
|
||||
api_token_id: "{{ token_id | default(omit) }}"
|
||||
api_token_secret: "{{ token_secret | default(omit) }}"
|
||||
register: proxmox_storages
|
||||
|
||||
- name: List NFS storages only
|
||||
community.general.proxmox_storage_info:
|
||||
api_host: helldorado
|
||||
api_user: root@pam
|
||||
api_password: "{{ password | default(omit) }}"
|
||||
api_token_id: "{{ token_id | default(omit) }}"
|
||||
api_token_secret: "{{ token_secret | default(omit) }}"
|
||||
type: nfs
|
||||
register: proxmox_storages_nfs
|
||||
|
||||
- name: Retrieve information about the lvm2 storage
|
||||
community.general.proxmox_storage_info:
|
||||
api_host: helldorado
|
||||
api_user: root@pam
|
||||
api_password: "{{ password | default(omit) }}"
|
||||
api_token_id: "{{ token_id | default(omit) }}"
|
||||
api_token_secret: "{{ token_secret | default(omit) }}"
|
||||
storage: lvm2
|
||||
register: proxmox_storage_lvm
|
||||
'''
|
||||
|
||||
|
||||
RETURN = '''
|
||||
proxmox_storages:
|
||||
description: List of storage pools.
|
||||
returned: on success
|
||||
type: list
|
||||
elements: dict
|
||||
contains:
|
||||
content:
|
||||
description: Proxmox content types available in this storage
|
||||
returned: on success
|
||||
type: list
|
||||
elements: str
|
||||
digest:
|
||||
description: Storage's digest
|
||||
returned: on success
|
||||
type: str
|
||||
nodes:
|
||||
description: List of nodes associated to this storage
|
||||
returned: on success, if storage is not local
|
||||
type: list
|
||||
elements: str
|
||||
path:
|
||||
description: Physical path to this storage
|
||||
returned: on success
|
||||
type: str
|
||||
prune-backups:
|
||||
description: Backup retention options
|
||||
returned: on success
|
||||
type: list
|
||||
elements: dict
|
||||
shared:
|
||||
description: Is this storage shared
|
||||
returned: on success
|
||||
type: bool
|
||||
storage:
|
||||
description: Storage name
|
||||
returned: on success
|
||||
type: str
|
||||
type:
|
||||
description: Storage type
|
||||
returned: on success
|
||||
type: str
|
||||
'''
|
||||
|
||||
|
||||
from ansible.module_utils.basic import AnsibleModule, missing_required_lib
|
||||
from ansible_collections.community.general.plugins.module_utils.proxmox import (
|
||||
proxmox_auth_argument_spec, ProxmoxAnsible, HAS_PROXMOXER, PROXMOXER_IMP_ERR, proxmox_to_ansible_bool)
|
||||
|
||||
|
||||
class ProxmoxStorageInfoAnsible(ProxmoxAnsible):
|
||||
def get_storage(self, storage):
|
||||
try:
|
||||
storage = self.proxmox_api.storage.get(storage)
|
||||
except Exception:
|
||||
self.module.fail_json(msg="Storage '%s' does not exist" % storage)
|
||||
return ProxmoxStorage(storage)
|
||||
|
||||
def get_storages(self, type=None):
|
||||
storages = self.proxmox_api.storage.get(type=type)
|
||||
storages = [ProxmoxStorage(storage) for storage in storages]
|
||||
return storages
|
||||
|
||||
|
||||
class ProxmoxStorage:
|
||||
def __init__(self, storage):
|
||||
self.storage = storage
|
||||
# Convert proxmox representation of lists, dicts and boolean for easier
|
||||
# manipulation within ansible.
|
||||
if 'shared' in self.storage:
|
||||
self.storage['shared'] = proxmox_to_ansible_bool(self.storage['shared'])
|
||||
if 'content' in self.storage:
|
||||
self.storage['content'] = self.storage['content'].split(',')
|
||||
if 'nodes' in self.storage:
|
||||
self.storage['nodes'] = self.storage['nodes'].split(',')
|
||||
if 'prune-backups' in storage:
|
||||
options = storage['prune-backups'].split(',')
|
||||
self.storage['prune-backups'] = dict()
|
||||
for option in options:
|
||||
k, v = option.split('=')
|
||||
self.storage['prune-backups'][k] = v
|
||||
|
||||
|
||||
def proxmox_storage_info_argument_spec():
|
||||
return dict(
|
||||
storage=dict(type='str', aliases=['name']),
|
||||
type=dict(type='str'),
|
||||
)
|
||||
|
||||
|
||||
def main():
|
||||
module_args = proxmox_auth_argument_spec()
|
||||
storage_info_args = proxmox_storage_info_argument_spec()
|
||||
module_args.update(storage_info_args)
|
||||
|
||||
module = AnsibleModule(
|
||||
argument_spec=module_args,
|
||||
required_one_of=[('api_password', 'api_token_id')],
|
||||
required_together=[('api_token_id', 'api_token_secret')],
|
||||
mutually_exclusive=[('storage', 'type')],
|
||||
supports_check_mode=True
|
||||
)
|
||||
result = dict(
|
||||
changed=False
|
||||
)
|
||||
|
||||
if not HAS_PROXMOXER:
|
||||
module.fail_json(msg=missing_required_lib('proxmoxer'), exception=PROXMOXER_IMP_ERR)
|
||||
|
||||
proxmox = ProxmoxStorageInfoAnsible(module)
|
||||
storage = module.params['storage']
|
||||
storagetype = module.params['type']
|
||||
|
||||
if storage:
|
||||
storages = [proxmox.get_storage(storage)]
|
||||
else:
|
||||
storages = proxmox.get_storages(type=storagetype)
|
||||
result['proxmox_storages'] = [storage.storage for storage in storages]
|
||||
|
||||
module.exit_json(**result)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
@@ -122,7 +122,7 @@ try:
|
||||
except ImportError:
|
||||
HAS_PROXMOXER = False
|
||||
|
||||
from ansible.module_utils.basic import AnsibleModule
|
||||
from ansible.module_utils.basic import AnsibleModule, env_fallback
|
||||
|
||||
|
||||
def get_template(proxmox, node, storage, content_type, template):
|
||||
@@ -175,7 +175,7 @@ def main():
|
||||
module = AnsibleModule(
|
||||
argument_spec=dict(
|
||||
api_host=dict(required=True),
|
||||
api_password=dict(no_log=True),
|
||||
api_password=dict(no_log=True, fallback=(env_fallback, ['PROXMOX_PASSWORD'])),
|
||||
api_token_id=dict(no_log=True),
|
||||
api_token_secret=dict(no_log=True),
|
||||
api_user=dict(required=True),
|
||||
@@ -188,7 +188,10 @@ def main():
|
||||
timeout=dict(type='int', default=30),
|
||||
force=dict(type='bool', default=False),
|
||||
state=dict(default='present', choices=['present', 'absent']),
|
||||
)
|
||||
),
|
||||
required_together=[('api_token_id', 'api_token_secret')],
|
||||
required_one_of=[('api_password', 'api_token_id')],
|
||||
required_if=[('state', 'absent', ['template'])]
|
||||
)
|
||||
|
||||
if not HAS_PROXMOXER:
|
||||
@@ -207,12 +210,6 @@ def main():
|
||||
|
||||
auth_args = {'user': api_user}
|
||||
if not (api_token_id and api_token_secret):
|
||||
# If password not set get it from PROXMOX_PASSWORD env
|
||||
if not api_password:
|
||||
try:
|
||||
api_password = os.environ['PROXMOX_PASSWORD']
|
||||
except KeyError as e:
|
||||
module.fail_json(msg='You should set api_password param or use PROXMOX_PASSWORD environment variable')
|
||||
auth_args['password'] = api_password
|
||||
else:
|
||||
auth_args['token_name'] = api_token_id
|
||||
@@ -261,9 +258,7 @@ def main():
|
||||
content_type = module.params['content_type']
|
||||
template = module.params['template']
|
||||
|
||||
if not template:
|
||||
module.fail_json(msg='template param is mandatory')
|
||||
elif not get_template(proxmox, node, storage, content_type, template):
|
||||
if not get_template(proxmox, node, storage, content_type, template):
|
||||
module.exit_json(changed=False, msg='template with volid=%s:%s/%s is already deleted' % (storage, content_type, template))
|
||||
|
||||
if delete_template(module, proxmox, node, storage, content_type, template, timeout):
|
||||
|
||||
@@ -57,27 +57,32 @@ options:
|
||||
Each rule must contain protocol parameter, in addition to three optional parameters
|
||||
(port_from, port_to, and source)
|
||||
type: list
|
||||
elements: dict
|
||||
add_server_ips:
|
||||
description:
|
||||
- A list of server identifiers (id or name) to be assigned to a firewall policy.
|
||||
Used in combination with update state.
|
||||
type: list
|
||||
elements: str
|
||||
required: false
|
||||
remove_server_ips:
|
||||
description:
|
||||
- A list of server IP ids to be unassigned from a firewall policy. Used in combination with update state.
|
||||
type: list
|
||||
elements: str
|
||||
required: false
|
||||
add_rules:
|
||||
description:
|
||||
- A list of rules that will be added to an existing firewall policy.
|
||||
It is syntax is the same as the one used for rules parameter. Used in combination with update state.
|
||||
type: list
|
||||
elements: dict
|
||||
required: false
|
||||
remove_rules:
|
||||
description:
|
||||
- A list of rule ids that will be removed from an existing firewall policy. Used in combination with update state.
|
||||
type: list
|
||||
elements: str
|
||||
required: false
|
||||
description:
|
||||
description:
|
||||
@@ -500,7 +505,7 @@ def main():
|
||||
module = AnsibleModule(
|
||||
argument_spec=dict(
|
||||
auth_token=dict(
|
||||
type='str',
|
||||
type='str', no_log=True,
|
||||
default=os.environ.get('ONEANDONE_AUTH_TOKEN')),
|
||||
api_url=dict(
|
||||
type='str',
|
||||
@@ -508,11 +513,11 @@ def main():
|
||||
name=dict(type='str'),
|
||||
firewall_policy=dict(type='str'),
|
||||
description=dict(type='str'),
|
||||
rules=dict(type='list', default=[]),
|
||||
add_server_ips=dict(type='list', default=[]),
|
||||
remove_server_ips=dict(type='list', default=[]),
|
||||
add_rules=dict(type='list', default=[]),
|
||||
remove_rules=dict(type='list', default=[]),
|
||||
rules=dict(type='list', elements="dict", default=[]),
|
||||
add_server_ips=dict(type='list', elements="str", default=[]),
|
||||
remove_server_ips=dict(type='list', elements="str", default=[]),
|
||||
add_rules=dict(type='list', elements="dict", default=[]),
|
||||
remove_rules=dict(type='list', elements="str", default=[]),
|
||||
wait=dict(type='bool', default=True),
|
||||
wait_timeout=dict(type='int', default=600),
|
||||
wait_interval=dict(type='int', default=5),
|
||||
|
||||
@@ -95,6 +95,7 @@ options:
|
||||
- A list of rule objects that will be set for the load balancer. Each rule must contain protocol,
|
||||
port_balancer, and port_server parameters, in addition to source parameter, which is optional.
|
||||
type: list
|
||||
elements: dict
|
||||
description:
|
||||
description:
|
||||
- Description of the load balancer. maxLength=256
|
||||
@@ -105,22 +106,26 @@ options:
|
||||
- A list of server identifiers (id or name) to be assigned to a load balancer.
|
||||
Used in combination with update state.
|
||||
type: list
|
||||
elements: str
|
||||
required: false
|
||||
remove_server_ips:
|
||||
description:
|
||||
- A list of server IP ids to be unassigned from a load balancer. Used in combination with update state.
|
||||
type: list
|
||||
elements: str
|
||||
required: false
|
||||
add_rules:
|
||||
description:
|
||||
- A list of rules that will be added to an existing load balancer.
|
||||
It is syntax is the same as the one used for rules parameter. Used in combination with update state.
|
||||
type: list
|
||||
elements: dict
|
||||
required: false
|
||||
remove_rules:
|
||||
description:
|
||||
- A list of rule ids that will be removed from an existing load balancer. Used in combination with update state.
|
||||
type: list
|
||||
elements: str
|
||||
required: false
|
||||
wait:
|
||||
description:
|
||||
@@ -594,7 +599,7 @@ def main():
|
||||
module = AnsibleModule(
|
||||
argument_spec=dict(
|
||||
auth_token=dict(
|
||||
type='str',
|
||||
type='str', no_log=True,
|
||||
default=os.environ.get('ONEANDONE_AUTH_TOKEN')),
|
||||
api_url=dict(
|
||||
type='str',
|
||||
@@ -613,11 +618,11 @@ def main():
|
||||
choices=METHODS),
|
||||
datacenter=dict(
|
||||
choices=DATACENTERS),
|
||||
rules=dict(type='list', default=[]),
|
||||
add_server_ips=dict(type='list', default=[]),
|
||||
remove_server_ips=dict(type='list', default=[]),
|
||||
add_rules=dict(type='list', default=[]),
|
||||
remove_rules=dict(type='list', default=[]),
|
||||
rules=dict(type='list', elements="dict", default=[]),
|
||||
add_server_ips=dict(type='list', elements="str", default=[]),
|
||||
remove_server_ips=dict(type='list', elements="str", default=[]),
|
||||
add_rules=dict(type='list', elements="dict", default=[]),
|
||||
remove_rules=dict(type='list', elements="str", default=[]),
|
||||
wait=dict(type='bool', default=True),
|
||||
wait_timeout=dict(type='int', default=600),
|
||||
wait_interval=dict(type='int', default=5),
|
||||
|
||||
@@ -71,6 +71,7 @@ options:
|
||||
warning alerts, critical is used to set critical alerts. alert enables alert,
|
||||
and value is used to advise when the value is exceeded.
|
||||
type: list
|
||||
elements: dict
|
||||
suboptions:
|
||||
cpu:
|
||||
description:
|
||||
@@ -96,6 +97,7 @@ options:
|
||||
description:
|
||||
- Array of ports that will be monitoring.
|
||||
type: list
|
||||
elements: dict
|
||||
suboptions:
|
||||
protocol:
|
||||
description:
|
||||
@@ -119,6 +121,7 @@ options:
|
||||
description:
|
||||
- Array of processes that will be monitoring.
|
||||
type: list
|
||||
elements: dict
|
||||
suboptions:
|
||||
process:
|
||||
description:
|
||||
@@ -133,41 +136,49 @@ options:
|
||||
description:
|
||||
- Ports to add to the monitoring policy.
|
||||
type: list
|
||||
elements: dict
|
||||
required: false
|
||||
add_processes:
|
||||
description:
|
||||
- Processes to add to the monitoring policy.
|
||||
type: list
|
||||
elements: dict
|
||||
required: false
|
||||
add_servers:
|
||||
description:
|
||||
- Servers to add to the monitoring policy.
|
||||
type: list
|
||||
elements: str
|
||||
required: false
|
||||
remove_ports:
|
||||
description:
|
||||
- Ports to remove from the monitoring policy.
|
||||
type: list
|
||||
elements: str
|
||||
required: false
|
||||
remove_processes:
|
||||
description:
|
||||
- Processes to remove from the monitoring policy.
|
||||
type: list
|
||||
elements: str
|
||||
required: false
|
||||
remove_servers:
|
||||
description:
|
||||
- Servers to remove from the monitoring policy.
|
||||
type: list
|
||||
elements: str
|
||||
required: false
|
||||
update_ports:
|
||||
description:
|
||||
- Ports to be updated on the monitoring policy.
|
||||
type: list
|
||||
elements: dict
|
||||
required: false
|
||||
update_processes:
|
||||
description:
|
||||
- Processes to be updated on the monitoring policy.
|
||||
type: list
|
||||
elements: dict
|
||||
required: false
|
||||
wait:
|
||||
description:
|
||||
@@ -197,7 +208,7 @@ author:
|
||||
|
||||
EXAMPLES = '''
|
||||
- name: Create a monitoring policy
|
||||
oneandone_moitoring_policy:
|
||||
community.general.oneandone_monitoring_policy:
|
||||
auth_token: oneandone_private_api_key
|
||||
name: ansible monitoring policy
|
||||
description: Testing creation of a monitoring policy with ansible
|
||||
@@ -258,13 +269,13 @@ EXAMPLES = '''
|
||||
wait: true
|
||||
|
||||
- name: Destroy a monitoring policy
|
||||
oneandone_moitoring_policy:
|
||||
community.general.oneandone_monitoring_policy:
|
||||
auth_token: oneandone_private_api_key
|
||||
state: absent
|
||||
name: ansible monitoring policy
|
||||
|
||||
- name: Update a monitoring policy
|
||||
oneandone_moitoring_policy:
|
||||
community.general.oneandone_monitoring_policy:
|
||||
auth_token: oneandone_private_api_key
|
||||
monitoring_policy: ansible monitoring policy
|
||||
name: ansible monitoring policy updated
|
||||
@@ -315,7 +326,7 @@ EXAMPLES = '''
|
||||
state: update
|
||||
|
||||
- name: Add a port to a monitoring policy
|
||||
oneandone_moitoring_policy:
|
||||
community.general.oneandone_monitoring_policy:
|
||||
auth_token: oneandone_private_api_key
|
||||
monitoring_policy: ansible monitoring policy updated
|
||||
add_ports:
|
||||
@@ -328,7 +339,7 @@ EXAMPLES = '''
|
||||
state: update
|
||||
|
||||
- name: Update existing ports of a monitoring policy
|
||||
oneandone_moitoring_policy:
|
||||
community.general.oneandone_monitoring_policy:
|
||||
auth_token: oneandone_private_api_key
|
||||
monitoring_policy: ansible monitoring policy updated
|
||||
update_ports:
|
||||
@@ -348,7 +359,7 @@ EXAMPLES = '''
|
||||
state: update
|
||||
|
||||
- name: Remove a port from a monitoring policy
|
||||
oneandone_moitoring_policy:
|
||||
community.general.oneandone_monitoring_policy:
|
||||
auth_token: oneandone_private_api_key
|
||||
monitoring_policy: ansible monitoring policy updated
|
||||
remove_ports:
|
||||
@@ -356,7 +367,7 @@ EXAMPLES = '''
|
||||
state: update
|
||||
|
||||
- name: Add a process to a monitoring policy
|
||||
oneandone_moitoring_policy:
|
||||
community.general.oneandone_monitoring_policy:
|
||||
auth_token: oneandone_private_api_key
|
||||
monitoring_policy: ansible monitoring policy updated
|
||||
add_processes:
|
||||
@@ -368,7 +379,7 @@ EXAMPLES = '''
|
||||
state: update
|
||||
|
||||
- name: Update existing processes of a monitoring policy
|
||||
oneandone_moitoring_policy:
|
||||
community.general.oneandone_monitoring_policy:
|
||||
auth_token: oneandone_private_api_key
|
||||
monitoring_policy: ansible monitoring policy updated
|
||||
update_processes:
|
||||
@@ -386,7 +397,7 @@ EXAMPLES = '''
|
||||
state: update
|
||||
|
||||
- name: Remove a process from a monitoring policy
|
||||
oneandone_moitoring_policy:
|
||||
community.general.oneandone_monitoring_policy:
|
||||
auth_token: oneandone_private_api_key
|
||||
monitoring_policy: ansible monitoring policy updated
|
||||
remove_processes:
|
||||
@@ -395,7 +406,7 @@ EXAMPLES = '''
|
||||
state: update
|
||||
|
||||
- name: Add server to a monitoring policy
|
||||
oneandone_moitoring_policy:
|
||||
community.general.oneandone_monitoring_policy:
|
||||
auth_token: oneandone_private_api_key
|
||||
monitoring_policy: ansible monitoring policy updated
|
||||
add_servers:
|
||||
@@ -404,7 +415,7 @@ EXAMPLES = '''
|
||||
state: update
|
||||
|
||||
- name: Remove server from a monitoring policy
|
||||
oneandone_moitoring_policy:
|
||||
community.general.oneandone_monitoring_policy:
|
||||
auth_token: oneandone_private_api_key
|
||||
monitoring_policy: ansible monitoring policy updated
|
||||
remove_servers:
|
||||
@@ -695,15 +706,15 @@ def update_monitoring_policy(module, oneandone_conn):
|
||||
threshold_entities = ['cpu', 'ram', 'disk', 'internal_ping', 'transfer']
|
||||
|
||||
_thresholds = []
|
||||
for treshold in thresholds:
|
||||
key = treshold.keys()[0]
|
||||
for threshold in thresholds:
|
||||
key = list(threshold.keys())[0]
|
||||
if key in threshold_entities:
|
||||
_threshold = oneandone.client.Threshold(
|
||||
entity=key,
|
||||
warning_value=treshold[key]['warning']['value'],
|
||||
warning_alert=str(treshold[key]['warning']['alert']).lower(),
|
||||
critical_value=treshold[key]['critical']['value'],
|
||||
critical_alert=str(treshold[key]['critical']['alert']).lower())
|
||||
warning_value=threshold[key]['warning']['value'],
|
||||
warning_alert=str(threshold[key]['warning']['alert']).lower(),
|
||||
critical_value=threshold[key]['critical']['value'],
|
||||
critical_alert=str(threshold[key]['critical']['alert']).lower())
|
||||
_thresholds.append(_threshold)
|
||||
|
||||
if name or description or email or thresholds:
|
||||
@@ -864,15 +875,15 @@ def create_monitoring_policy(module, oneandone_conn):
|
||||
threshold_entities = ['cpu', 'ram', 'disk', 'internal_ping', 'transfer']
|
||||
|
||||
_thresholds = []
|
||||
for treshold in thresholds:
|
||||
key = treshold.keys()[0]
|
||||
for threshold in thresholds:
|
||||
key = list(threshold.keys())[0]
|
||||
if key in threshold_entities:
|
||||
_threshold = oneandone.client.Threshold(
|
||||
entity=key,
|
||||
warning_value=treshold[key]['warning']['value'],
|
||||
warning_alert=str(treshold[key]['warning']['alert']).lower(),
|
||||
critical_value=treshold[key]['critical']['value'],
|
||||
critical_alert=str(treshold[key]['critical']['alert']).lower())
|
||||
warning_value=threshold[key]['warning']['value'],
|
||||
warning_alert=str(threshold[key]['warning']['alert']).lower(),
|
||||
critical_value=threshold[key]['critical']['value'],
|
||||
critical_alert=str(threshold[key]['critical']['alert']).lower())
|
||||
_thresholds.append(_threshold)
|
||||
|
||||
_ports = []
|
||||
@@ -947,7 +958,7 @@ def main():
|
||||
module = AnsibleModule(
|
||||
argument_spec=dict(
|
||||
auth_token=dict(
|
||||
type='str',
|
||||
type='str', no_log=True,
|
||||
default=os.environ.get('ONEANDONE_AUTH_TOKEN')),
|
||||
api_url=dict(
|
||||
type='str',
|
||||
@@ -957,17 +968,17 @@ def main():
|
||||
agent=dict(type='str'),
|
||||
email=dict(type='str'),
|
||||
description=dict(type='str'),
|
||||
thresholds=dict(type='list', default=[]),
|
||||
ports=dict(type='list', default=[]),
|
||||
processes=dict(type='list', default=[]),
|
||||
add_ports=dict(type='list', default=[]),
|
||||
update_ports=dict(type='list', default=[]),
|
||||
remove_ports=dict(type='list', default=[]),
|
||||
add_processes=dict(type='list', default=[]),
|
||||
update_processes=dict(type='list', default=[]),
|
||||
remove_processes=dict(type='list', default=[]),
|
||||
add_servers=dict(type='list', default=[]),
|
||||
remove_servers=dict(type='list', default=[]),
|
||||
thresholds=dict(type='list', elements="dict", default=[]),
|
||||
ports=dict(type='list', elements="dict", default=[]),
|
||||
processes=dict(type='list', elements="dict", default=[]),
|
||||
add_ports=dict(type='list', elements="dict", default=[]),
|
||||
update_ports=dict(type='list', elements="dict", default=[]),
|
||||
remove_ports=dict(type='list', elements="str", default=[]),
|
||||
add_processes=dict(type='list', elements="dict", default=[]),
|
||||
update_processes=dict(type='list', elements="dict", default=[]),
|
||||
remove_processes=dict(type='list', elements="str", default=[]),
|
||||
add_servers=dict(type='list', elements="str", default=[]),
|
||||
remove_servers=dict(type='list', elements="str", default=[]),
|
||||
wait=dict(type='bool', default=True),
|
||||
wait_timeout=dict(type='int', default=600),
|
||||
wait_interval=dict(type='int', default=5),
|
||||
|
||||
@@ -71,10 +71,12 @@ options:
|
||||
description:
|
||||
- List of server identifiers (name or id) to be added to the private network.
|
||||
type: list
|
||||
elements: str
|
||||
remove_members:
|
||||
description:
|
||||
- List of server identifiers (name or id) to be removed from the private network.
|
||||
type: list
|
||||
elements: str
|
||||
wait:
|
||||
description:
|
||||
- wait for the instance to be in state 'running' before returning
|
||||
@@ -384,7 +386,7 @@ def main():
|
||||
module = AnsibleModule(
|
||||
argument_spec=dict(
|
||||
auth_token=dict(
|
||||
type='str',
|
||||
type='str', no_log=True,
|
||||
default=os.environ.get('ONEANDONE_AUTH_TOKEN')),
|
||||
api_url=dict(
|
||||
type='str',
|
||||
@@ -394,8 +396,8 @@ def main():
|
||||
description=dict(type='str'),
|
||||
network_address=dict(type='str'),
|
||||
subnet_mask=dict(type='str'),
|
||||
add_members=dict(type='list', default=[]),
|
||||
remove_members=dict(type='list', default=[]),
|
||||
add_members=dict(type='list', elements="str", default=[]),
|
||||
remove_members=dict(type='list', elements="str", default=[]),
|
||||
datacenter=dict(
|
||||
choices=DATACENTERS),
|
||||
wait=dict(type='bool', default=True),
|
||||
|
||||
@@ -274,7 +274,7 @@ def main():
|
||||
module = AnsibleModule(
|
||||
argument_spec=dict(
|
||||
auth_token=dict(
|
||||
type='str',
|
||||
type='str', no_log=True,
|
||||
default=os.environ.get('ONEANDONE_AUTH_TOKEN')),
|
||||
api_url=dict(
|
||||
type='str',
|
||||
|
||||
@@ -87,6 +87,7 @@ options:
|
||||
- A list of hard disks with nested "size" and "is_main" properties.
|
||||
It must be provided with vcore, cores_per_processor, and ram parameters.
|
||||
type: list
|
||||
elements: dict
|
||||
private_network:
|
||||
description:
|
||||
- The private network name or ID.
|
||||
@@ -627,7 +628,7 @@ def main():
|
||||
vcore=dict(type='int'),
|
||||
cores_per_processor=dict(type='int'),
|
||||
ram=dict(type='float'),
|
||||
hdds=dict(type='list'),
|
||||
hdds=dict(type='list', elements='dict'),
|
||||
count=dict(type='int', default=1),
|
||||
ssh_key=dict(type='raw'),
|
||||
auto_increment=dict(type='bool', default=True),
|
||||
|
||||
@@ -66,6 +66,7 @@ options:
|
||||
description:
|
||||
- The labels for this host.
|
||||
type: list
|
||||
elements: str
|
||||
template:
|
||||
description:
|
||||
- The template or attribute changes to merge into the host template.
|
||||
@@ -130,7 +131,7 @@ class HostModule(OpenNebulaModule):
|
||||
vmm_mad_name=dict(type='str', default="kvm"),
|
||||
cluster_id=dict(type='int', default=0),
|
||||
cluster_name=dict(type='str'),
|
||||
labels=dict(type='list'),
|
||||
labels=dict(type='list', elements='str'),
|
||||
template=dict(type='dict', aliases=['attributes']),
|
||||
)
|
||||
|
||||
|
||||
@@ -56,6 +56,7 @@ options:
|
||||
- A list of images ids whose facts you want to gather.
|
||||
aliases: ['id']
|
||||
type: list
|
||||
elements: str
|
||||
name:
|
||||
description:
|
||||
- A C(name) of the image whose facts will be gathered.
|
||||
@@ -253,7 +254,7 @@ def main():
|
||||
"api_url": {"required": False, "type": "str"},
|
||||
"api_username": {"required": False, "type": "str"},
|
||||
"api_password": {"required": False, "type": "str", "no_log": True},
|
||||
"ids": {"required": False, "aliases": ['id'], "type": "list"},
|
||||
"ids": {"required": False, "aliases": ['id'], "type": "list", "elements": "str"},
|
||||
"name": {"required": False, "type": "str"},
|
||||
}
|
||||
|
||||
@@ -273,9 +274,6 @@ def main():
|
||||
name = params.get('name')
|
||||
client = pyone.OneServer(auth.url, session=auth.username + ':' + auth.password)
|
||||
|
||||
result = {'images': []}
|
||||
images = []
|
||||
|
||||
if ids:
|
||||
images = get_images_by_ids(module, client, ids)
|
||||
elif name:
|
||||
@@ -283,8 +281,9 @@ def main():
|
||||
else:
|
||||
images = get_all_images(client).IMAGE
|
||||
|
||||
for image in images:
|
||||
result['images'].append(get_image_info(image))
|
||||
result = {
|
||||
'images': [get_image_info(image) for image in images],
|
||||
}
|
||||
|
||||
module.exit_json(**result)
|
||||
|
||||
|
||||
@@ -72,6 +72,7 @@ options:
|
||||
- A list of instance ids used for states':' C(absent), C(running), C(rebooted), C(poweredoff)
|
||||
aliases: ['ids']
|
||||
type: list
|
||||
elements: int
|
||||
state:
|
||||
description:
|
||||
- C(present) - create instances from a template specified with C(template_id)/C(template_name).
|
||||
@@ -120,6 +121,7 @@ options:
|
||||
- C(state) of instances with these labels.
|
||||
default: []
|
||||
type: list
|
||||
elements: str
|
||||
count_attributes:
|
||||
description:
|
||||
- A dictionary of key/value attributes that can only be used with
|
||||
@@ -134,6 +136,7 @@ options:
|
||||
- This can be expressed in multiple ways and is shown in the EXAMPLES
|
||||
- section.
|
||||
type: list
|
||||
elements: str
|
||||
count:
|
||||
description:
|
||||
- Number of instances to launch
|
||||
@@ -168,6 +171,7 @@ options:
|
||||
- NOTE':' If The Template hats Multiple Disks the Order of the Sizes is
|
||||
- matched against the order specified in C(template_id)/C(template_name).
|
||||
type: list
|
||||
elements: str
|
||||
cpu:
|
||||
description:
|
||||
- Percentage of CPU divided by 100 required for the new instance. Half a
|
||||
@@ -182,6 +186,7 @@ options:
|
||||
- A list of dictionaries with network parameters. See examples for more details.
|
||||
default: []
|
||||
type: list
|
||||
elements: dict
|
||||
disk_saveas:
|
||||
description:
|
||||
- Creates an image from a VM disk.
|
||||
@@ -1349,7 +1354,7 @@ def main():
|
||||
"api_url": {"required": False, "type": "str"},
|
||||
"api_username": {"required": False, "type": "str"},
|
||||
"api_password": {"required": False, "type": "str", "no_log": True},
|
||||
"instance_ids": {"required": False, "aliases": ['ids'], "type": "list"},
|
||||
"instance_ids": {"required": False, "aliases": ['ids'], "type": "list", "elements": "int"},
|
||||
"template_name": {"required": False, "type": "str"},
|
||||
"template_id": {"required": False, "type": "int"},
|
||||
"vm_start_on_hold": {"default": False, "type": "bool"},
|
||||
@@ -1367,16 +1372,16 @@ def main():
|
||||
"memory": {"required": False, "type": "str"},
|
||||
"cpu": {"required": False, "type": "float"},
|
||||
"vcpu": {"required": False, "type": "int"},
|
||||
"disk_size": {"required": False, "type": "list"},
|
||||
"disk_size": {"required": False, "type": "list", "elements": "str"},
|
||||
"datastore_name": {"required": False, "type": "str"},
|
||||
"datastore_id": {"required": False, "type": "int"},
|
||||
"networks": {"default": [], "type": "list"},
|
||||
"networks": {"default": [], "type": "list", "elements": "dict"},
|
||||
"count": {"default": 1, "type": "int"},
|
||||
"exact_count": {"required": False, "type": "int"},
|
||||
"attributes": {"default": {}, "type": "dict"},
|
||||
"count_attributes": {"required": False, "type": "dict"},
|
||||
"labels": {"default": [], "type": "list"},
|
||||
"count_labels": {"required": False, "type": "list"},
|
||||
"labels": {"default": [], "type": "list", "elements": "str"},
|
||||
"count_labels": {"required": False, "type": "list", "elements": "str"},
|
||||
"disk_saveas": {"type": "dict"},
|
||||
"persistent": {"default": False, "type": "bool"}
|
||||
}
|
||||
|
||||
@@ -128,7 +128,7 @@ def update_vcn(virtual_network_client, module):
|
||||
primitive_params_update=["vcn_id"],
|
||||
kwargs_non_primitive_update={UpdateVcnDetails: "update_vcn_details"},
|
||||
module=module,
|
||||
update_attributes=UpdateVcnDetails().attribute_map.keys(),
|
||||
update_attributes=list(UpdateVcnDetails().attribute_map.keys()),
|
||||
)
|
||||
return result
|
||||
|
||||
|
||||
@@ -137,17 +137,13 @@ def main():
|
||||
host = search_by_name(hosts_service, module.params['host'])
|
||||
if host is None:
|
||||
raise Exception("Host '%s' was not found." % module.params['host'])
|
||||
tags.extend([
|
||||
tag for tag in hosts_service.host_service(host.id).tags_service().list()
|
||||
])
|
||||
tags.extend(hosts_service.host_service(host.id).tags_service().list())
|
||||
if module.params['vm']:
|
||||
vms_service = connection.system_service().vms_service()
|
||||
vm = search_by_name(vms_service, module.params['vm'])
|
||||
if vm is None:
|
||||
raise Exception("Vm '%s' was not found." % module.params['vm'])
|
||||
tags.extend([
|
||||
tag for tag in vms_service.vm_service(vm.id).tags_service().list()
|
||||
])
|
||||
tags.extend(vms_service.vm_service(vm.id).tags_service().list())
|
||||
|
||||
if not (module.params['vm'] or module.params['host'] or module.params['name']):
|
||||
tags = all_tags
|
||||
|
||||
@@ -31,20 +31,25 @@ options:
|
||||
auth_token:
|
||||
description:
|
||||
- Packet API token. You can also supply it in env var C(PACKET_API_TOKEN).
|
||||
type: str
|
||||
|
||||
count:
|
||||
description:
|
||||
- The number of devices to create. Count number can be included in hostname via the %d string formatter.
|
||||
default: 1
|
||||
type: int
|
||||
|
||||
count_offset:
|
||||
description:
|
||||
- From which number to start the count.
|
||||
default: 1
|
||||
type: int
|
||||
|
||||
device_ids:
|
||||
description:
|
||||
- List of device IDs on which to operate.
|
||||
type: list
|
||||
elements: str
|
||||
|
||||
tags:
|
||||
description:
|
||||
@@ -57,10 +62,12 @@ options:
|
||||
facility:
|
||||
description:
|
||||
- Facility slug for device creation. See Packet API for current list - U(https://www.packet.net/developers/api/facilities/).
|
||||
type: str
|
||||
|
||||
features:
|
||||
description:
|
||||
- Dict with "features" for device creation. See Packet API docs for details.
|
||||
type: dict
|
||||
|
||||
hostnames:
|
||||
description:
|
||||
@@ -68,6 +75,8 @@ options:
|
||||
- If given string or one-item list, you can use the C("%d") Python string format to expand numbers from I(count).
|
||||
- If only one hostname, it might be expanded to list if I(count)>1.
|
||||
aliases: [name]
|
||||
type: list
|
||||
elements: str
|
||||
|
||||
locked:
|
||||
description:
|
||||
@@ -79,15 +88,18 @@ options:
|
||||
operating_system:
|
||||
description:
|
||||
- OS slug for device creation. See Packet API for current list - U(https://www.packet.net/developers/api/operatingsystems/).
|
||||
type: str
|
||||
|
||||
plan:
|
||||
description:
|
||||
- Plan slug for device creation. See Packet API for current list - U(https://www.packet.net/developers/api/plans/).
|
||||
type: str
|
||||
|
||||
project_id:
|
||||
description:
|
||||
- ID of project of the device.
|
||||
required: true
|
||||
type: str
|
||||
|
||||
state:
|
||||
description:
|
||||
@@ -96,10 +108,12 @@ options:
|
||||
- If set to C(active), the module call will block until all the specified devices are in state active due to the Packet API, or until I(wait_timeout).
|
||||
choices: [present, absent, active, inactive, rebooted]
|
||||
default: present
|
||||
type: str
|
||||
|
||||
user_data:
|
||||
description:
|
||||
- Userdata blob made available to the machine
|
||||
type: str
|
||||
|
||||
wait_for_public_IPv:
|
||||
description:
|
||||
@@ -107,16 +121,21 @@ options:
|
||||
- If set to 4, it will wait until IPv4 is assigned to the instance.
|
||||
- If set to 6, wait until public IPv6 is assigned to the instance.
|
||||
choices: [4,6]
|
||||
type: int
|
||||
|
||||
wait_timeout:
|
||||
description:
|
||||
- How long (seconds) to wait either for automatic IP address assignment, or for the device to reach the C(active) I(state).
|
||||
- If I(wait_for_public_IPv) is set and I(state) is C(active), the module will wait for both events consequently, applying the timeout twice.
|
||||
default: 900
|
||||
type: int
|
||||
|
||||
ipxe_script_url:
|
||||
description:
|
||||
- URL of custom iPXE script for provisioning.
|
||||
- More about custom iPXE for Packet devices at U(https://help.packet.net/technical/infrastructure/custom-ipxe).
|
||||
type: str
|
||||
|
||||
always_pxe:
|
||||
description:
|
||||
- Persist PXE as the first boot option.
|
||||
@@ -601,10 +620,10 @@ def main():
|
||||
no_log=True),
|
||||
count=dict(type='int', default=1),
|
||||
count_offset=dict(type='int', default=1),
|
||||
device_ids=dict(type='list'),
|
||||
device_ids=dict(type='list', elements='str'),
|
||||
facility=dict(),
|
||||
features=dict(type='dict'),
|
||||
hostnames=dict(type='list', aliases=['name']),
|
||||
hostnames=dict(type='list', elements='str', aliases=['name']),
|
||||
tags=dict(type='list', elements='str'),
|
||||
locked=dict(type='bool', default=False, aliases=['lock']),
|
||||
operating_system=dict(),
|
||||
|
||||
@@ -17,27 +17,35 @@ author: "Tomas Karasek (@t0mk) <tom.to.the.k@gmail.com>"
|
||||
options:
|
||||
state:
|
||||
description:
|
||||
- Indicate desired state of the target.
|
||||
- Indicate desired state of the target.
|
||||
default: present
|
||||
choices: ['present', 'absent']
|
||||
type: str
|
||||
auth_token:
|
||||
description:
|
||||
- Packet API token. You can also supply it in env var C(PACKET_API_TOKEN).
|
||||
- Packet API token. You can also supply it in env var C(PACKET_API_TOKEN).
|
||||
type: str
|
||||
label:
|
||||
description:
|
||||
- Label for the key. If you keep it empty, it will be read from key string.
|
||||
description:
|
||||
- Label for the key. If you keep it empty, it will be read from key string.
|
||||
type: str
|
||||
aliases: [name]
|
||||
id:
|
||||
description:
|
||||
- UUID of the key which you want to remove.
|
||||
- UUID of the key which you want to remove.
|
||||
type: str
|
||||
fingerprint:
|
||||
description:
|
||||
- Fingerprint of the key which you want to remove.
|
||||
- Fingerprint of the key which you want to remove.
|
||||
type: str
|
||||
key:
|
||||
description:
|
||||
- Public Key string ({type} {base64 encoded key} {description}).
|
||||
- Public Key string ({type} {base64 encoded key} {description}).
|
||||
type: str
|
||||
key_file:
|
||||
description:
|
||||
- File with the public key.
|
||||
- File with the public key.
|
||||
type: path
|
||||
|
||||
requirements:
|
||||
- "python >= 2.6"
|
||||
|
||||
@@ -181,7 +181,6 @@ def do_detach(packet_conn, vol, dev_id=None):
|
||||
return (dev_id is None) or (a['device']['id'] == dev_id)
|
||||
for a in vol['attachments']:
|
||||
if dev_match(a):
|
||||
print(a['href'])
|
||||
packet_conn.call_api(a['href'], type="DELETE")
|
||||
|
||||
|
||||
|
||||
@@ -35,6 +35,7 @@ options:
|
||||
description:
|
||||
- Public SSH keys allowing access to the virtual machine.
|
||||
type: list
|
||||
elements: str
|
||||
datacenter:
|
||||
description:
|
||||
- The datacenter to provision this virtual machine.
|
||||
@@ -70,6 +71,7 @@ options:
|
||||
description:
|
||||
- list of instance ids, currently only used when state='absent' to remove instances.
|
||||
type: list
|
||||
elements: str
|
||||
count:
|
||||
description:
|
||||
- The number of virtual machines to create.
|
||||
@@ -581,12 +583,12 @@ def main():
|
||||
volume_size=dict(type='int', default=10),
|
||||
disk_type=dict(choices=['HDD', 'SSD'], default='HDD'),
|
||||
image_password=dict(default=None, no_log=True),
|
||||
ssh_keys=dict(type='list', default=[]),
|
||||
ssh_keys=dict(type='list', elements='str', default=[]),
|
||||
bus=dict(choices=['VIRTIO', 'IDE'], default='VIRTIO'),
|
||||
lan=dict(type='int', default=1),
|
||||
count=dict(type='int', default=1),
|
||||
auto_increment=dict(type='bool', default=True),
|
||||
instance_ids=dict(type='list', default=[]),
|
||||
instance_ids=dict(type='list', elements='str', default=[]),
|
||||
subscription_user=dict(),
|
||||
subscription_password=dict(no_log=True),
|
||||
location=dict(choices=LOCATIONS, default='us/las'),
|
||||
|
||||
@@ -47,6 +47,7 @@ options:
|
||||
description:
|
||||
- Public SSH keys allowing access to the virtual machine.
|
||||
type: list
|
||||
elements: str
|
||||
required: false
|
||||
disk_type:
|
||||
description:
|
||||
@@ -77,6 +78,7 @@ options:
|
||||
description:
|
||||
- list of instance ids, currently only used when state='absent' to remove instances.
|
||||
type: list
|
||||
elements: str
|
||||
required: false
|
||||
subscription_user:
|
||||
description:
|
||||
@@ -106,6 +108,10 @@ options:
|
||||
type: str
|
||||
required: false
|
||||
default: 'present'
|
||||
server:
|
||||
description:
|
||||
- Server name to attach the volume to.
|
||||
type: str
|
||||
|
||||
requirements: [ "profitbricks" ]
|
||||
author: Matt Baldwin (@baldwinSPC) <baldwin@stackpointcloud.com>
|
||||
@@ -369,13 +375,13 @@ def main():
|
||||
size=dict(type='int', default=10),
|
||||
bus=dict(choices=['VIRTIO', 'IDE'], default='VIRTIO'),
|
||||
image=dict(),
|
||||
image_password=dict(default=None, no_log=True),
|
||||
ssh_keys=dict(type='list', default=[]),
|
||||
image_password=dict(no_log=True),
|
||||
ssh_keys=dict(type='list', elements='str', default=[]),
|
||||
disk_type=dict(choices=['HDD', 'SSD'], default='HDD'),
|
||||
licence_type=dict(default='UNKNOWN'),
|
||||
count=dict(type='int', default=1),
|
||||
auto_increment=dict(type='bool', default=True),
|
||||
instance_ids=dict(type='list', default=[]),
|
||||
instance_ids=dict(type='list', elements='str', default=[]),
|
||||
subscription_user=dict(),
|
||||
subscription_password=dict(no_log=True),
|
||||
wait=dict(type='bool', default=True),
|
||||
|
||||
@@ -111,6 +111,7 @@ options:
|
||||
required: false
|
||||
default: []
|
||||
type: list
|
||||
elements: dict
|
||||
changes:
|
||||
description:
|
||||
- "List of fields which should be changed by block itself (doesn't
|
||||
@@ -552,7 +553,7 @@ def main():
|
||||
state=dict(default='present', type='str',
|
||||
choices=['started', 'stopped', 'present', 'absent']),
|
||||
name=dict(required=True, type='str'), description=dict(type='str'),
|
||||
event_handlers=dict(default=list(), type='list'),
|
||||
event_handlers=dict(default=list(), type='list', elements='dict'),
|
||||
changes=dict(default=dict(), type='dict'),
|
||||
cache=dict(default=dict(), type='dict'),
|
||||
validate_certs=dict(default=True, type='bool'))
|
||||
|
||||
@@ -238,7 +238,7 @@ def main():
|
||||
loadbalancer=dict(required=True),
|
||||
state=dict(default='present', choices=['present', 'absent']),
|
||||
enabled=dict(type='bool', default=True),
|
||||
private_key=dict(),
|
||||
private_key=dict(no_log=True),
|
||||
certificate=dict(),
|
||||
intermediate_certificate=dict(),
|
||||
secure_port=dict(type='int', default=443),
|
||||
|
||||
@@ -70,6 +70,7 @@ options:
|
||||
|
||||
tags:
|
||||
type: list
|
||||
elements: str
|
||||
description:
|
||||
- List of tags to apply to the instance (5 max)
|
||||
required: false
|
||||
@@ -652,7 +653,7 @@ def main():
|
||||
enable_ipv6=dict(default=False, type="bool"),
|
||||
public_ip=dict(default="absent"),
|
||||
state=dict(choices=list(state_strategy.keys()), default='present'),
|
||||
tags=dict(type="list", default=[]),
|
||||
tags=dict(type="list", elements="str", default=[]),
|
||||
organization=dict(required=True),
|
||||
wait=dict(type="bool", default=False),
|
||||
wait_timeout=dict(type="int", default=300),
|
||||
|
||||
@@ -63,6 +63,7 @@ options:
|
||||
|
||||
tags:
|
||||
type: list
|
||||
elements: str
|
||||
description:
|
||||
- List of tags to apply to the load-balancer
|
||||
|
||||
@@ -338,7 +339,7 @@ def main():
|
||||
description=dict(required=True),
|
||||
region=dict(required=True, choices=SCALEWAY_REGIONS),
|
||||
state=dict(choices=list(state_strategy.keys()), default='present'),
|
||||
tags=dict(type="list", default=[]),
|
||||
tags=dict(type="list", elements="str", default=[]),
|
||||
organization_id=dict(required=True),
|
||||
wait=dict(type="bool", default=False),
|
||||
wait_timeout=dict(type="int", default=300),
|
||||
|
||||
@@ -78,6 +78,7 @@ options:
|
||||
description:
|
||||
- A list of disks to add, valid properties are documented in vmadm(1M).
|
||||
type: list
|
||||
elements: dict
|
||||
dns_domain:
|
||||
required: false
|
||||
description:
|
||||
@@ -93,6 +94,7 @@ options:
|
||||
description:
|
||||
- Mount additional filesystems into an OS VM.
|
||||
type: list
|
||||
elements: dict
|
||||
firewall_enabled:
|
||||
required: false
|
||||
description:
|
||||
@@ -198,6 +200,7 @@ options:
|
||||
description:
|
||||
- A list of nics to add, valid properties are documented in vmadm(1M).
|
||||
type: list
|
||||
elements: dict
|
||||
nowait:
|
||||
required: false
|
||||
description:
|
||||
@@ -230,6 +233,7 @@ options:
|
||||
description:
|
||||
- List of resolvers to be put into C(/etc/resolv.conf).
|
||||
type: list
|
||||
elements: dict
|
||||
routes:
|
||||
required: false
|
||||
description:
|
||||
@@ -670,7 +674,6 @@ def main():
|
||||
'zfs_snapshot_limit'
|
||||
],
|
||||
'dict': ['customer_metadata', 'internal_metadata', 'routes'],
|
||||
'list': ['disks', 'nics', 'resolvers', 'filesystems']
|
||||
}
|
||||
|
||||
# Start with the options that are not as trivial as those above.
|
||||
@@ -697,6 +700,10 @@ def main():
|
||||
# Regular strings, however these require additional options.
|
||||
spice_password=dict(type='str', no_log=True),
|
||||
vnc_password=dict(type='str', no_log=True),
|
||||
disks=dict(type='list', elements='dict'),
|
||||
nics=dict(type='list', elements='dict'),
|
||||
resolvers=dict(type='list', elements='dict'),
|
||||
filesystems=dict(type='list', elements='dict'),
|
||||
)
|
||||
|
||||
# Add our 'simple' options to options dict.
|
||||
|
||||
@@ -115,6 +115,7 @@ options:
|
||||
- List of disk sizes to be assigned to new virtual instance.
|
||||
default: [ 25 ]
|
||||
type: list
|
||||
elements: int
|
||||
os_code:
|
||||
description:
|
||||
- OS Code to be used for new virtual instance.
|
||||
@@ -140,6 +141,7 @@ options:
|
||||
description:
|
||||
- List of ssh keys by their Id to be assigned to a virtual instance.
|
||||
type: list
|
||||
elements: str
|
||||
post_uri:
|
||||
description:
|
||||
- URL of a post provisioning script to be loaded and executed on virtual instance.
|
||||
@@ -396,13 +398,13 @@ def main():
|
||||
cpus=dict(type='int', choices=CPU_SIZES),
|
||||
memory=dict(type='int', choices=MEMORY_SIZES),
|
||||
flavor=dict(type='str'),
|
||||
disks=dict(type='list', default=[25]),
|
||||
disks=dict(type='list', elements='int', default=[25]),
|
||||
os_code=dict(type='str'),
|
||||
image_id=dict(type='str'),
|
||||
nic_speed=dict(type='int', choices=NIC_SPEEDS),
|
||||
public_vlan=dict(type='str'),
|
||||
private_vlan=dict(type='str'),
|
||||
ssh_keys=dict(type='list', default=[]),
|
||||
ssh_keys=dict(type='list', elements='str', default=[]),
|
||||
post_uri=dict(type='str'),
|
||||
state=dict(type='str', default='present', choices=STATES),
|
||||
wait=dict(type='bool', default=True),
|
||||
|
||||
@@ -1305,10 +1305,8 @@ def expand_tags(eg_launchspec, tags):
|
||||
|
||||
for tag in tags:
|
||||
eg_tag = spotinst.aws_elastigroup.Tag()
|
||||
if tag.keys():
|
||||
eg_tag.tag_key = tag.keys()[0]
|
||||
if tag.values():
|
||||
eg_tag.tag_value = tag.values()[0]
|
||||
if tag:
|
||||
eg_tag.tag_key, eg_tag.tag_value = list(tag.items())[0]
|
||||
|
||||
eg_tags.append(eg_tag)
|
||||
|
||||
@@ -1459,7 +1457,7 @@ def main():
|
||||
min_size=dict(type='int', required=True),
|
||||
monitoring=dict(type='str'),
|
||||
multai_load_balancers=dict(type='list'),
|
||||
multai_token=dict(type='str'),
|
||||
multai_token=dict(type='str', no_log=True),
|
||||
name=dict(type='str', required=True),
|
||||
network_interfaces=dict(type='list'),
|
||||
on_demand_count=dict(type='int'),
|
||||
@@ -1483,7 +1481,7 @@ def main():
|
||||
target_group_arns=dict(type='list'),
|
||||
tenancy=dict(type='str'),
|
||||
terminate_at_end_of_billing_hour=dict(type='bool'),
|
||||
token=dict(type='str'),
|
||||
token=dict(type='str', no_log=True),
|
||||
unit=dict(type='str'),
|
||||
user_data=dict(type='str'),
|
||||
utilize_reserved_instances=dict(type='bool'),
|
||||
|
||||
@@ -35,17 +35,20 @@ options:
|
||||
description:
|
||||
- The name of the application
|
||||
required: true
|
||||
type: str
|
||||
|
||||
state:
|
||||
description:
|
||||
- Whether the application should exist
|
||||
choices: ['present', 'absent']
|
||||
default: "present"
|
||||
type: str
|
||||
|
||||
type:
|
||||
description:
|
||||
- The type of application to create. See the Webfaction docs at U(https://docs.webfaction.com/xmlrpc-api/apps.html) for a list.
|
||||
required: true
|
||||
type: str
|
||||
|
||||
autostart:
|
||||
description:
|
||||
@@ -57,6 +60,7 @@ options:
|
||||
description:
|
||||
- Any extra parameters required by the app
|
||||
default: ''
|
||||
type: str
|
||||
|
||||
port_open:
|
||||
description:
|
||||
@@ -68,15 +72,18 @@ options:
|
||||
description:
|
||||
- The webfaction account to use
|
||||
required: true
|
||||
type: str
|
||||
|
||||
login_password:
|
||||
description:
|
||||
- The webfaction password to use
|
||||
required: true
|
||||
type: str
|
||||
|
||||
machine:
|
||||
description:
|
||||
- The machine name to use (optional for accounts with only one machine)
|
||||
type: str
|
||||
|
||||
'''
|
||||
|
||||
|
||||
@@ -32,36 +32,43 @@ options:
|
||||
description:
|
||||
- The name of the database
|
||||
required: true
|
||||
type: str
|
||||
|
||||
state:
|
||||
description:
|
||||
- Whether the database should exist
|
||||
choices: ['present', 'absent']
|
||||
default: "present"
|
||||
type: str
|
||||
|
||||
type:
|
||||
description:
|
||||
- The type of database to create.
|
||||
required: true
|
||||
choices: ['mysql', 'postgresql']
|
||||
type: str
|
||||
|
||||
password:
|
||||
description:
|
||||
- The password for the new database user.
|
||||
type: str
|
||||
|
||||
login_name:
|
||||
description:
|
||||
- The webfaction account to use
|
||||
required: true
|
||||
type: str
|
||||
|
||||
login_password:
|
||||
description:
|
||||
- The webfaction password to use
|
||||
required: true
|
||||
type: str
|
||||
|
||||
machine:
|
||||
description:
|
||||
- The machine name to use (optional for accounts with only one machine)
|
||||
type: str
|
||||
'''
|
||||
|
||||
EXAMPLES = '''
|
||||
|
||||
@@ -32,27 +32,33 @@ options:
|
||||
description:
|
||||
- The name of the domain
|
||||
required: true
|
||||
type: str
|
||||
|
||||
state:
|
||||
description:
|
||||
- Whether the domain should exist
|
||||
choices: ['present', 'absent']
|
||||
default: "present"
|
||||
type: str
|
||||
|
||||
subdomains:
|
||||
description:
|
||||
- Any subdomains to create.
|
||||
default: []
|
||||
type: list
|
||||
elements: str
|
||||
|
||||
login_name:
|
||||
description:
|
||||
- The webfaction account to use
|
||||
required: true
|
||||
type: str
|
||||
|
||||
login_password:
|
||||
description:
|
||||
- The webfaction password to use
|
||||
required: true
|
||||
type: str
|
||||
'''
|
||||
|
||||
EXAMPLES = '''
|
||||
@@ -87,8 +93,8 @@ def main():
|
||||
module = AnsibleModule(
|
||||
argument_spec=dict(
|
||||
name=dict(required=True),
|
||||
state=dict(required=False, choices=['present', 'absent'], default='present'),
|
||||
subdomains=dict(required=False, default=[], type='list'),
|
||||
state=dict(choices=['present', 'absent'], default='present'),
|
||||
subdomains=dict(default=[], type='list', elements='str'),
|
||||
login_name=dict(required=True),
|
||||
login_password=dict(required=True, no_log=True),
|
||||
),
|
||||
|
||||
@@ -29,27 +29,32 @@ options:
|
||||
description:
|
||||
- The name of the mailbox
|
||||
required: true
|
||||
type: str
|
||||
|
||||
mailbox_password:
|
||||
description:
|
||||
- The password for the mailbox
|
||||
required: true
|
||||
type: str
|
||||
|
||||
state:
|
||||
description:
|
||||
- Whether the mailbox should exist
|
||||
choices: ['present', 'absent']
|
||||
default: "present"
|
||||
type: str
|
||||
|
||||
login_name:
|
||||
description:
|
||||
- The webfaction account to use
|
||||
required: true
|
||||
type: str
|
||||
|
||||
login_password:
|
||||
description:
|
||||
- The webfaction password to use
|
||||
required: true
|
||||
type: str
|
||||
'''
|
||||
|
||||
EXAMPLES = '''
|
||||
|
||||
@@ -33,17 +33,20 @@ options:
|
||||
description:
|
||||
- The name of the website
|
||||
required: true
|
||||
type: str
|
||||
|
||||
state:
|
||||
description:
|
||||
- Whether the website should exist
|
||||
choices: ['present', 'absent']
|
||||
default: "present"
|
||||
type: str
|
||||
|
||||
host:
|
||||
description:
|
||||
- The webfaction host on which the site should be created.
|
||||
required: true
|
||||
type: str
|
||||
|
||||
https:
|
||||
description:
|
||||
@@ -55,21 +58,27 @@ options:
|
||||
description:
|
||||
- A mapping of URLs to apps
|
||||
default: []
|
||||
type: list
|
||||
elements: list
|
||||
|
||||
subdomains:
|
||||
description:
|
||||
- A list of subdomains associated with this site.
|
||||
default: []
|
||||
type: list
|
||||
elements: str
|
||||
|
||||
login_name:
|
||||
description:
|
||||
- The webfaction account to use
|
||||
required: true
|
||||
type: str
|
||||
|
||||
login_password:
|
||||
description:
|
||||
- The webfaction password to use
|
||||
required: true
|
||||
type: str
|
||||
'''
|
||||
|
||||
EXAMPLES = '''
|
||||
@@ -101,12 +110,12 @@ def main():
|
||||
module = AnsibleModule(
|
||||
argument_spec=dict(
|
||||
name=dict(required=True),
|
||||
state=dict(required=False, choices=['present', 'absent'], default='present'),
|
||||
state=dict(choices=['present', 'absent'], default='present'),
|
||||
# You can specify an IP address or hostname.
|
||||
host=dict(required=True),
|
||||
https=dict(required=False, type='bool', default=False),
|
||||
subdomains=dict(required=False, type='list', default=[]),
|
||||
site_apps=dict(required=False, type='list', default=[]),
|
||||
subdomains=dict(type='list', elements='str', default=[]),
|
||||
site_apps=dict(type='list', elements='list', default=[]),
|
||||
login_name=dict(required=True),
|
||||
login_password=dict(required=True, no_log=True),
|
||||
),
|
||||
|
||||
@@ -33,6 +33,7 @@ requirements:
|
||||
author: "Steve Gargan (@sgargan)"
|
||||
options:
|
||||
state:
|
||||
type: str
|
||||
description:
|
||||
- register or deregister the consul service, defaults to present
|
||||
default: present
|
||||
@@ -86,6 +87,7 @@ options:
|
||||
documentation for further details.
|
||||
tags:
|
||||
type: list
|
||||
elements: str
|
||||
description:
|
||||
- tags that will be attached to the service registration.
|
||||
script:
|
||||
@@ -345,7 +347,7 @@ def remove_service(module, service_id):
|
||||
module.exit_json(changed=False, id=service_id)
|
||||
|
||||
|
||||
def get_consul_api(module, token=None):
|
||||
def get_consul_api(module):
|
||||
consulClient = consul.Consul(host=module.params.get('host'),
|
||||
port=module.params.get('port'),
|
||||
scheme=module.params.get('scheme'),
|
||||
@@ -398,7 +400,7 @@ def parse_service(module):
|
||||
module.fail_json(msg="service_name is required to configure a service.")
|
||||
|
||||
|
||||
class ConsulService():
|
||||
class ConsulService(object):
|
||||
|
||||
def __init__(self, service_id=None, name=None, address=None, port=-1,
|
||||
tags=None, loaded=None):
|
||||
@@ -564,26 +566,26 @@ def main():
|
||||
argument_spec=dict(
|
||||
host=dict(default='localhost'),
|
||||
port=dict(default=8500, type='int'),
|
||||
scheme=dict(required=False, default='http'),
|
||||
validate_certs=dict(required=False, default=True, type='bool'),
|
||||
check_id=dict(required=False),
|
||||
check_name=dict(required=False),
|
||||
check_node=dict(required=False),
|
||||
check_host=dict(required=False),
|
||||
notes=dict(required=False),
|
||||
script=dict(required=False),
|
||||
service_id=dict(required=False),
|
||||
service_name=dict(required=False),
|
||||
service_address=dict(required=False, type='str', default=None),
|
||||
service_port=dict(required=False, type='int', default=None),
|
||||
scheme=dict(default='http'),
|
||||
validate_certs=dict(default=True, type='bool'),
|
||||
check_id=dict(),
|
||||
check_name=dict(),
|
||||
check_node=dict(),
|
||||
check_host=dict(),
|
||||
notes=dict(),
|
||||
script=dict(),
|
||||
service_id=dict(),
|
||||
service_name=dict(),
|
||||
service_address=dict(type='str'),
|
||||
service_port=dict(type='int'),
|
||||
state=dict(default='present', choices=['present', 'absent']),
|
||||
interval=dict(required=False, type='str'),
|
||||
ttl=dict(required=False, type='str'),
|
||||
tcp=dict(required=False, type='str'),
|
||||
http=dict(required=False, type='str'),
|
||||
timeout=dict(required=False, type='str'),
|
||||
tags=dict(required=False, type='list'),
|
||||
token=dict(required=False, no_log=True)
|
||||
interval=dict(type='str'),
|
||||
ttl=dict(type='str'),
|
||||
tcp=dict(type='str'),
|
||||
http=dict(type='str'),
|
||||
timeout=dict(type='str'),
|
||||
tags=dict(type='list', elements='str'),
|
||||
token=dict(no_log=True)
|
||||
),
|
||||
supports_check_mode=False,
|
||||
)
|
||||
|
||||
@@ -22,29 +22,35 @@ options:
|
||||
description:
|
||||
- a management token is required to manipulate the acl lists
|
||||
required: true
|
||||
type: str
|
||||
state:
|
||||
description:
|
||||
- whether the ACL pair should be present or absent
|
||||
required: false
|
||||
choices: ['present', 'absent']
|
||||
default: present
|
||||
type: str
|
||||
token_type:
|
||||
description:
|
||||
- the type of token that should be created
|
||||
choices: ['client', 'management']
|
||||
default: client
|
||||
type: str
|
||||
name:
|
||||
description:
|
||||
- the name that should be associated with the acl key, this is opaque
|
||||
to Consul
|
||||
required: false
|
||||
type: str
|
||||
token:
|
||||
description:
|
||||
- the token key identifying an ACL rule set. If generated by consul
|
||||
this will be a UUID
|
||||
required: false
|
||||
type: str
|
||||
rules:
|
||||
type: list
|
||||
elements: dict
|
||||
description:
|
||||
- rules that should be associated with a given token
|
||||
required: false
|
||||
@@ -53,6 +59,7 @@ options:
|
||||
- host of the consul agent defaults to localhost
|
||||
required: false
|
||||
default: localhost
|
||||
type: str
|
||||
port:
|
||||
type: int
|
||||
description:
|
||||
@@ -64,6 +71,7 @@ options:
|
||||
- the protocol scheme on which the consul agent is running
|
||||
required: false
|
||||
default: http
|
||||
type: str
|
||||
validate_certs:
|
||||
type: bool
|
||||
description:
|
||||
@@ -215,14 +223,14 @@ _POLICY_HCL_PROPERTY = "policy"
|
||||
_ARGUMENT_SPEC = {
|
||||
MANAGEMENT_PARAMETER_NAME: dict(required=True, no_log=True),
|
||||
HOST_PARAMETER_NAME: dict(default='localhost'),
|
||||
SCHEME_PARAMETER_NAME: dict(required=False, default='http'),
|
||||
VALIDATE_CERTS_PARAMETER_NAME: dict(required=False, type='bool', default=True),
|
||||
NAME_PARAMETER_NAME: dict(required=False),
|
||||
SCHEME_PARAMETER_NAME: dict(default='http'),
|
||||
VALIDATE_CERTS_PARAMETER_NAME: dict(type='bool', default=True),
|
||||
NAME_PARAMETER_NAME: dict(),
|
||||
PORT_PARAMETER_NAME: dict(default=8500, type='int'),
|
||||
RULES_PARAMETER_NAME: dict(default=None, required=False, type='list'),
|
||||
RULES_PARAMETER_NAME: dict(type='list', elements='dict'),
|
||||
STATE_PARAMETER_NAME: dict(default=PRESENT_STATE_VALUE, choices=[PRESENT_STATE_VALUE, ABSENT_STATE_VALUE]),
|
||||
TOKEN_PARAMETER_NAME: dict(required=False),
|
||||
TOKEN_TYPE_PARAMETER_NAME: dict(required=False, choices=[CLIENT_TOKEN_TYPE_VALUE, MANAGEMENT_TOKEN_TYPE_VALUE],
|
||||
TOKEN_PARAMETER_NAME: dict(),
|
||||
TOKEN_TYPE_PARAMETER_NAME: dict(choices=[CLIENT_TOKEN_TYPE_VALUE, MANAGEMENT_TOKEN_TYPE_VALUE],
|
||||
default=CLIENT_TOKEN_TYPE_VALUE)
|
||||
}
|
||||
|
||||
|
||||
@@ -37,6 +37,7 @@ options:
|
||||
'release' respectively. a valid session must be supplied to make the
|
||||
attempt changed will be true if the attempt is successful, false
|
||||
otherwise.
|
||||
type: str
|
||||
choices: [ absent, acquire, present, release ]
|
||||
default: present
|
||||
key:
|
||||
|
||||
@@ -67,6 +67,7 @@ options:
|
||||
associated with the session will be release and can be acquired once
|
||||
the associated lock delay has expired.
|
||||
type: list
|
||||
elements: str
|
||||
host:
|
||||
description:
|
||||
- The host of the consul agent defaults to localhost.
|
||||
@@ -237,7 +238,7 @@ def test_dependencies(module):
|
||||
|
||||
def main():
|
||||
argument_spec = dict(
|
||||
checks=dict(type='list'),
|
||||
checks=dict(type='list', elements='str'),
|
||||
delay=dict(type='int', default='15'),
|
||||
behavior=dict(type='str', default='release', choices=['release', 'delete']),
|
||||
host=dict(type='str', default='localhost'),
|
||||
|
||||
@@ -18,47 +18,58 @@ description:
|
||||
- Needs python etcd3 lib to work
|
||||
options:
|
||||
key:
|
||||
type: str
|
||||
description:
|
||||
- the key where the information is stored in the cluster
|
||||
required: true
|
||||
value:
|
||||
type: str
|
||||
description:
|
||||
- the information stored
|
||||
required: true
|
||||
host:
|
||||
type: str
|
||||
description:
|
||||
- the IP address of the cluster
|
||||
default: 'localhost'
|
||||
port:
|
||||
type: int
|
||||
description:
|
||||
- the port number used to connect to the cluster
|
||||
default: 2379
|
||||
state:
|
||||
type: str
|
||||
description:
|
||||
- the state of the value for the key.
|
||||
- can be present or absent
|
||||
required: true
|
||||
choices: [ present, absent ]
|
||||
user:
|
||||
type: str
|
||||
description:
|
||||
- The etcd user to authenticate with.
|
||||
password:
|
||||
type: str
|
||||
description:
|
||||
- The password to use for authentication.
|
||||
- Required if I(user) is defined.
|
||||
ca_cert:
|
||||
type: path
|
||||
description:
|
||||
- The Certificate Authority to use to verify the etcd host.
|
||||
- Required if I(client_cert) and I(client_key) are defined.
|
||||
client_cert:
|
||||
type: path
|
||||
description:
|
||||
- PEM formatted certificate chain file to be used for SSL client authentication.
|
||||
- Required if I(client_key) is defined.
|
||||
client_key:
|
||||
type: path
|
||||
description:
|
||||
- PEM formatted file that contains your private key to be used for SSL client authentication.
|
||||
- Required if I(client_cert) is defined.
|
||||
timeout:
|
||||
type: int
|
||||
description:
|
||||
- The socket level timeout in seconds.
|
||||
author:
|
||||
|
||||
@@ -312,12 +312,11 @@ def run():
|
||||
)
|
||||
|
||||
changed = False
|
||||
nomad_jobs = list()
|
||||
result = list()
|
||||
try:
|
||||
job_list = nomad_client.jobs.get_jobs()
|
||||
for job in job_list:
|
||||
nomad_jobs.append(nomad_client.job.get_job(job.get('ID')))
|
||||
result = nomad_jobs
|
||||
result.append(nomad_client.job.get_job(job.get('ID')))
|
||||
except Exception as e:
|
||||
module.fail_json(msg=to_native(e))
|
||||
|
||||
|
||||
@@ -17,25 +17,31 @@ options:
|
||||
description:
|
||||
- A list of ZooKeeper servers (format '[server]:[port]').
|
||||
required: true
|
||||
type: str
|
||||
name:
|
||||
description:
|
||||
- The path of the znode.
|
||||
required: true
|
||||
type: str
|
||||
value:
|
||||
description:
|
||||
- The value assigned to the znode.
|
||||
type: str
|
||||
op:
|
||||
description:
|
||||
- An operation to perform. Mutually exclusive with state.
|
||||
choices: [ get, wait, list ]
|
||||
type: str
|
||||
state:
|
||||
description:
|
||||
- The state to enforce. Mutually exclusive with op.
|
||||
choices: [ present, absent ]
|
||||
type: str
|
||||
timeout:
|
||||
description:
|
||||
- The amount of time to wait for a node to appear.
|
||||
default: 300
|
||||
type: int
|
||||
recursive:
|
||||
description:
|
||||
- Recursively delete node and all its children.
|
||||
@@ -110,11 +116,11 @@ def main():
|
||||
argument_spec=dict(
|
||||
hosts=dict(required=True, type='str'),
|
||||
name=dict(required=True, type='str'),
|
||||
value=dict(required=False, default=None, type='str'),
|
||||
op=dict(required=False, default=None, choices=['get', 'wait', 'list']),
|
||||
value=dict(type='str'),
|
||||
op=dict(choices=['get', 'wait', 'list']),
|
||||
state=dict(choices=['present', 'absent']),
|
||||
timeout=dict(required=False, default=300, type='int'),
|
||||
recursive=dict(required=False, default=False, type='bool')
|
||||
timeout=dict(default=300, type='int'),
|
||||
recursive=dict(default=False, type='bool')
|
||||
),
|
||||
supports_check_mode=False
|
||||
)
|
||||
|
||||
@@ -115,7 +115,6 @@ EXAMPLES = '''
|
||||
local_only: False
|
||||
|
||||
# example playbook:
|
||||
---
|
||||
- name: Upgrade aerospike
|
||||
hosts: all
|
||||
become: true
|
||||
@@ -338,7 +337,7 @@ class Migrations:
|
||||
namespace_tx = \
|
||||
int(namespace_stats[self.module.params['migrate_tx_key']])
|
||||
namespace_rx = \
|
||||
int(namespace_stats[self.module.params['migrate_tx_key']])
|
||||
int(namespace_stats[self.module.params['migrate_rx_key']])
|
||||
except KeyError:
|
||||
self.module.fail_json(
|
||||
msg="Did not find partition remaining key:" +
|
||||
|
||||
@@ -22,11 +22,13 @@ options:
|
||||
description:
|
||||
- Name of the plugin to install.
|
||||
required: True
|
||||
type: str
|
||||
state:
|
||||
description:
|
||||
- Desired state of a plugin.
|
||||
choices: ["present", "absent"]
|
||||
default: present
|
||||
type: str
|
||||
src:
|
||||
description:
|
||||
- Optionally set the source location to retrieve the plugin from. This can be a file://
|
||||
@@ -38,16 +40,19 @@ options:
|
||||
effect.
|
||||
- For ES 1.x use url.
|
||||
required: False
|
||||
type: str
|
||||
url:
|
||||
description:
|
||||
- Set exact URL to download the plugin from (Only works for ES 1.x).
|
||||
- For ES 2.x and higher, use src.
|
||||
required: False
|
||||
type: str
|
||||
timeout:
|
||||
description:
|
||||
- "Timeout setting: 30s, 1m, 1h..."
|
||||
- Only valid for Elasticsearch < 5.0. This option is ignored for Elasticsearch > 5.0.
|
||||
default: 1m
|
||||
type: str
|
||||
force:
|
||||
description:
|
||||
- "Force batch mode when installing plugins. This is only necessary if a plugin requires additional permissions and console detection fails."
|
||||
@@ -57,20 +62,25 @@ options:
|
||||
description:
|
||||
- Location of the plugin binary. If this file is not found, the default plugin binaries will be used.
|
||||
- The default changed in Ansible 2.4 to None.
|
||||
type: path
|
||||
plugin_dir:
|
||||
description:
|
||||
- Your configured plugin directory specified in Elasticsearch
|
||||
default: /usr/share/elasticsearch/plugins/
|
||||
type: path
|
||||
proxy_host:
|
||||
description:
|
||||
- Proxy host to use during plugin installation
|
||||
type: str
|
||||
proxy_port:
|
||||
description:
|
||||
- Proxy port to use during plugin installation
|
||||
type: str
|
||||
version:
|
||||
description:
|
||||
- Version of the plugin to be installed.
|
||||
If plugin exists with previous version, it will NOT be updated
|
||||
type: str
|
||||
'''
|
||||
|
||||
EXAMPLES = '''
|
||||
@@ -241,7 +251,7 @@ def main():
|
||||
module = AnsibleModule(
|
||||
argument_spec=dict(
|
||||
name=dict(required=True),
|
||||
state=dict(default="present", choices=PACKAGE_STATE_MAP.keys()),
|
||||
state=dict(default="present", choices=list(PACKAGE_STATE_MAP.keys())),
|
||||
src=dict(default=None),
|
||||
url=dict(default=None),
|
||||
timeout=dict(default="1m"),
|
||||
|
||||
@@ -22,31 +22,38 @@ options:
|
||||
description:
|
||||
- Name of the plugin to install.
|
||||
required: True
|
||||
type: str
|
||||
state:
|
||||
description:
|
||||
- Desired state of a plugin.
|
||||
choices: ["present", "absent"]
|
||||
default: present
|
||||
type: str
|
||||
url:
|
||||
description:
|
||||
- Set exact URL to download the plugin from.
|
||||
- For local file, prefix its absolute path with file://
|
||||
type: str
|
||||
timeout:
|
||||
description:
|
||||
- "Timeout setting: 30s, 1m, 1h etc."
|
||||
default: 1m
|
||||
type: str
|
||||
plugin_bin:
|
||||
description:
|
||||
- Location of the Kibana binary.
|
||||
default: /opt/kibana/bin/kibana
|
||||
type: path
|
||||
plugin_dir:
|
||||
description:
|
||||
- Your configured plugin directory specified in Kibana.
|
||||
default: /opt/kibana/installedPlugins/
|
||||
type: path
|
||||
version:
|
||||
description:
|
||||
- Version of the plugin to be installed.
|
||||
- If plugin exists with previous version, plugin will NOT be updated unless C(force) is set to yes.
|
||||
type: str
|
||||
force:
|
||||
description:
|
||||
- Delete and re-install the plugin. Can be useful for plugins update.
|
||||
@@ -209,7 +216,7 @@ def main():
|
||||
module = AnsibleModule(
|
||||
argument_spec=dict(
|
||||
name=dict(required=True),
|
||||
state=dict(default="present", choices=PACKAGE_STATE_MAP.keys()),
|
||||
state=dict(default="present", choices=list(PACKAGE_STATE_MAP.keys())),
|
||||
url=dict(default=None),
|
||||
timeout=dict(default="1m"),
|
||||
plugin_bin=dict(default="/opt/kibana/bin/kibana", type="path"),
|
||||
|
||||
@@ -23,28 +23,37 @@ options:
|
||||
description:
|
||||
- The command you would like to perform against the cluster.
|
||||
choices: ['ping', 'kv_test', 'join', 'plan', 'commit']
|
||||
type: str
|
||||
config_dir:
|
||||
description:
|
||||
- The path to the riak configuration directory
|
||||
default: /etc/riak
|
||||
type: path
|
||||
http_conn:
|
||||
description:
|
||||
- The ip address and port that is listening for Riak HTTP queries
|
||||
default: 127.0.0.1:8098
|
||||
type: str
|
||||
target_node:
|
||||
description:
|
||||
- The target node for certain operations (join, ping)
|
||||
default: riak@127.0.0.1
|
||||
type: str
|
||||
wait_for_handoffs:
|
||||
description:
|
||||
- Number of seconds to wait for handoffs to complete.
|
||||
type: int
|
||||
default: 0
|
||||
wait_for_ring:
|
||||
description:
|
||||
- Number of seconds to wait for all nodes to agree on the ring.
|
||||
type: int
|
||||
default: 0
|
||||
wait_for_service:
|
||||
description:
|
||||
- Waits for a riak service to come online before continuing.
|
||||
choices: ['kv']
|
||||
type: str
|
||||
validate_certs:
|
||||
description:
|
||||
- If C(no), SSL certificates will not be validated. This should only be used
|
||||
@@ -93,8 +102,8 @@ def main():
|
||||
config_dir=dict(default='/etc/riak', type='path'),
|
||||
http_conn=dict(required=False, default='127.0.0.1:8098'),
|
||||
target_node=dict(default='riak@127.0.0.1', required=False),
|
||||
wait_for_handoffs=dict(default=False, type='int'),
|
||||
wait_for_ring=dict(default=False, type='int'),
|
||||
wait_for_handoffs=dict(default=0, type='int'),
|
||||
wait_for_ring=dict(default=0, type='int'),
|
||||
wait_for_service=dict(
|
||||
required=False, default=None, choices=['kv']),
|
||||
validate_certs=dict(default=True, type='bool'))
|
||||
|
||||
@@ -14,11 +14,11 @@ short_description: Updates Vertica configuration parameters.
|
||||
description:
|
||||
- Updates Vertica configuration parameters.
|
||||
options:
|
||||
name:
|
||||
parameter:
|
||||
description:
|
||||
- Name of the parameter to update.
|
||||
required: true
|
||||
aliases: [parameter]
|
||||
aliases: [name]
|
||||
type: str
|
||||
value:
|
||||
description:
|
||||
|
||||
@@ -21,25 +21,30 @@ options:
|
||||
description:
|
||||
- Name of the cluster running the schema.
|
||||
default: localhost
|
||||
type: str
|
||||
port:
|
||||
description:
|
||||
Database port to connect to.
|
||||
default: 5433
|
||||
type: str
|
||||
db:
|
||||
description:
|
||||
- Name of the database running the schema.
|
||||
type: str
|
||||
login_user:
|
||||
description:
|
||||
- The username used to authenticate with.
|
||||
default: dbadmin
|
||||
type: str
|
||||
login_password:
|
||||
description:
|
||||
- The password used to authenticate with.
|
||||
type: str
|
||||
notes:
|
||||
- The default authentication assumes that you are either logging in as or sudo'ing
|
||||
to the C(dbadmin) account on the host.
|
||||
- This module uses C(pyodbc), a Python ODBC database adapter. You must ensure
|
||||
that C(unixODBC) and C(pyodbc) is installed on the host and properly configured.
|
||||
that C(unixODBC) and C(pyodbc) are installed on the host and properly configured.
|
||||
- Configuring C(unixODBC) for Vertica requires C(Driver = /opt/vertica/lib64/libverticaodbc.so)
|
||||
to be added to the C(Vertica) section of either C(/etc/odbcinst.ini) or C($HOME/.odbcinst.ini)
|
||||
and both C(ErrorMessagesPath = /opt/vertica/lib64) and C(DriverManagerEncoding = UTF-16)
|
||||
|
||||
@@ -15,37 +15,46 @@ short_description: Adds or removes Vertica database roles and assigns roles to t
|
||||
description:
|
||||
- Adds or removes Vertica database role and, optionally, assign other roles.
|
||||
options:
|
||||
name:
|
||||
role:
|
||||
description:
|
||||
- Name of the role to add or remove.
|
||||
required: true
|
||||
type: str
|
||||
aliases: ['name']
|
||||
assigned_roles:
|
||||
description:
|
||||
- Comma separated list of roles to assign to the role.
|
||||
aliases: ['assigned_role']
|
||||
type: str
|
||||
state:
|
||||
description:
|
||||
- Whether to create C(present), drop C(absent) or lock C(locked) a role.
|
||||
choices: ['present', 'absent']
|
||||
default: present
|
||||
type: str
|
||||
db:
|
||||
description:
|
||||
- Name of the Vertica database.
|
||||
type: str
|
||||
cluster:
|
||||
description:
|
||||
- Name of the Vertica cluster.
|
||||
default: localhost
|
||||
type: str
|
||||
port:
|
||||
description:
|
||||
- Vertica cluster port to connect to.
|
||||
default: 5433
|
||||
type: str
|
||||
login_user:
|
||||
description:
|
||||
- The username used to authenticate with.
|
||||
default: dbadmin
|
||||
type: str
|
||||
login_password:
|
||||
description:
|
||||
- The password used to authenticate with.
|
||||
type: str
|
||||
notes:
|
||||
- The default authentication assumes that you are either logging in as or sudo'ing
|
||||
to the C(dbadmin) account on the host.
|
||||
@@ -168,11 +177,11 @@ def main():
|
||||
role=dict(required=True, aliases=['name']),
|
||||
assigned_roles=dict(default=None, aliases=['assigned_role']),
|
||||
state=dict(default='present', choices=['absent', 'present']),
|
||||
db=dict(default=None),
|
||||
db=dict(),
|
||||
cluster=dict(default='localhost'),
|
||||
port=dict(default='5433'),
|
||||
login_user=dict(default='dbadmin'),
|
||||
login_password=dict(default=None, no_log=True),
|
||||
login_password=dict(no_log=True),
|
||||
), supports_check_mode=True)
|
||||
|
||||
if not pyodbc_found:
|
||||
|
||||
@@ -20,44 +20,55 @@ description:
|
||||
will fail and only remove roles created for the schema if they have
|
||||
no dependencies.
|
||||
options:
|
||||
name:
|
||||
schema:
|
||||
description:
|
||||
- Name of the schema to add or remove.
|
||||
required: true
|
||||
aliases: ['name']
|
||||
type: str
|
||||
usage_roles:
|
||||
description:
|
||||
- Comma separated list of roles to create and grant usage access to the schema.
|
||||
aliases: ['usage_role']
|
||||
type: str
|
||||
create_roles:
|
||||
description:
|
||||
- Comma separated list of roles to create and grant usage and create access to the schema.
|
||||
aliases: ['create_role']
|
||||
type: str
|
||||
owner:
|
||||
description:
|
||||
- Name of the user to set as owner of the schema.
|
||||
type: str
|
||||
state:
|
||||
description:
|
||||
- Whether to create C(present), or drop C(absent) a schema.
|
||||
default: present
|
||||
choices: ['present', 'absent']
|
||||
type: str
|
||||
db:
|
||||
description:
|
||||
- Name of the Vertica database.
|
||||
type: str
|
||||
cluster:
|
||||
description:
|
||||
- Name of the Vertica cluster.
|
||||
default: localhost
|
||||
type: str
|
||||
port:
|
||||
description:
|
||||
- Vertica cluster port to connect to.
|
||||
default: 5433
|
||||
type: str
|
||||
login_user:
|
||||
description:
|
||||
- The username used to authenticate with.
|
||||
default: dbadmin
|
||||
type: str
|
||||
login_password:
|
||||
description:
|
||||
- The password used to authenticate with.
|
||||
type: str
|
||||
notes:
|
||||
- The default authentication assumes that you are either logging in as or sudo'ing
|
||||
to the C(dbadmin) account on the host.
|
||||
@@ -230,15 +241,15 @@ def main():
|
||||
module = AnsibleModule(
|
||||
argument_spec=dict(
|
||||
schema=dict(required=True, aliases=['name']),
|
||||
usage_roles=dict(default=None, aliases=['usage_role']),
|
||||
create_roles=dict(default=None, aliases=['create_role']),
|
||||
owner=dict(default=None),
|
||||
usage_roles=dict(aliases=['usage_role']),
|
||||
create_roles=dict(aliases=['create_role']),
|
||||
owner=dict(),
|
||||
state=dict(default='present', choices=['absent', 'present']),
|
||||
db=dict(default=None),
|
||||
db=dict(),
|
||||
cluster=dict(default='localhost'),
|
||||
port=dict(default='5433'),
|
||||
login_user=dict(default='dbadmin'),
|
||||
login_password=dict(default=None, no_log=True),
|
||||
login_password=dict(no_log=True),
|
||||
), supports_check_mode=True)
|
||||
|
||||
if not pyodbc_found:
|
||||
|
||||
@@ -17,22 +17,27 @@ description:
|
||||
- In such a situation, if the module tries to remove the user it
|
||||
will fail and only remove roles granted to the user.
|
||||
options:
|
||||
name:
|
||||
user:
|
||||
description:
|
||||
- Name of the user to add or remove.
|
||||
required: true
|
||||
type: str
|
||||
aliases: ['name']
|
||||
profile:
|
||||
description:
|
||||
- Sets the user's profile.
|
||||
type: str
|
||||
resource_pool:
|
||||
description:
|
||||
- Sets the user's resource pool.
|
||||
type: str
|
||||
password:
|
||||
description:
|
||||
- The user's password encrypted by the MD5 algorithm.
|
||||
- The password must be generated with the format C("md5" + md5[password + username]),
|
||||
resulting in a total of 35 characters. An easy way to do this is by querying
|
||||
the Vertica database with select 'md5'||md5('<user_password><user_name>').
|
||||
type: str
|
||||
expired:
|
||||
description:
|
||||
- Sets the user's password expiration.
|
||||
@@ -46,29 +51,36 @@ options:
|
||||
description:
|
||||
- Comma separated list of roles to assign to the user.
|
||||
aliases: ['role']
|
||||
type: str
|
||||
state:
|
||||
description:
|
||||
- Whether to create C(present), drop C(absent) or lock C(locked) a user.
|
||||
choices: ['present', 'absent', 'locked']
|
||||
default: present
|
||||
type: str
|
||||
db:
|
||||
description:
|
||||
- Name of the Vertica database.
|
||||
type: str
|
||||
cluster:
|
||||
description:
|
||||
- Name of the Vertica cluster.
|
||||
default: localhost
|
||||
type: str
|
||||
port:
|
||||
description:
|
||||
- Vertica cluster port to connect to.
|
||||
default: 5433
|
||||
type: str
|
||||
login_user:
|
||||
description:
|
||||
- The username used to authenticate with.
|
||||
default: dbadmin
|
||||
type: str
|
||||
login_password:
|
||||
description:
|
||||
- The password used to authenticate with.
|
||||
type: str
|
||||
notes:
|
||||
- The default authentication assumes that you are either logging in as or sudo'ing
|
||||
to the C(dbadmin) account on the host.
|
||||
@@ -282,18 +294,18 @@ def main():
|
||||
module = AnsibleModule(
|
||||
argument_spec=dict(
|
||||
user=dict(required=True, aliases=['name']),
|
||||
profile=dict(default=None),
|
||||
resource_pool=dict(default=None),
|
||||
password=dict(default=None, no_log=True),
|
||||
expired=dict(type='bool', default=None),
|
||||
ldap=dict(type='bool', default=None),
|
||||
roles=dict(default=None, aliases=['role']),
|
||||
profile=dict(),
|
||||
resource_pool=dict(),
|
||||
password=dict(no_log=True),
|
||||
expired=dict(type='bool'),
|
||||
ldap=dict(type='bool'),
|
||||
roles=dict(aliases=['role']),
|
||||
state=dict(default='present', choices=['absent', 'present', 'locked']),
|
||||
db=dict(default=None),
|
||||
db=dict(),
|
||||
cluster=dict(default='localhost'),
|
||||
port=dict(default='5433'),
|
||||
login_user=dict(default='dbadmin'),
|
||||
login_password=dict(default=None, no_log=True),
|
||||
login_password=dict(no_log=True),
|
||||
), supports_check_mode=True)
|
||||
|
||||
if not pyodbc_found:
|
||||
|
||||
@@ -114,9 +114,7 @@ from ansible.module_utils.basic import AnsibleModule
|
||||
|
||||
def match_opt(option, line):
|
||||
option = re.escape(option)
|
||||
return re.match('( |\t)*%s( |\t)*(=|$)' % option, line) \
|
||||
or re.match('#( |\t)*%s( |\t)*(=|$)' % option, line) \
|
||||
or re.match(';( |\t)*%s( |\t)*(=|$)' % option, line)
|
||||
return re.match('[#;]?( |\t)*%s( |\t)*(=|$)' % option, line)
|
||||
|
||||
|
||||
def match_active_opt(option, line):
|
||||
@@ -251,9 +249,9 @@ def do_ini(module, filename, section=None, option=None, value=None,
|
||||
if not within_section and state == 'present':
|
||||
ini_lines.append('[%s]\n' % section)
|
||||
msg = 'section and option added'
|
||||
if option and value:
|
||||
if option and value is not None:
|
||||
ini_lines.append(assignment_format % (option, value))
|
||||
elif option and not value and allow_no_value:
|
||||
elif option and value is None and allow_no_value:
|
||||
ini_lines.append('%s\n' % option)
|
||||
else:
|
||||
msg = 'only section added'
|
||||
@@ -312,7 +310,7 @@ def main():
|
||||
allow_no_value = module.params['allow_no_value']
|
||||
create = module.params['create']
|
||||
|
||||
if state == 'present' and not allow_no_value and not value:
|
||||
if state == 'present' and not allow_no_value and value is None:
|
||||
module.fail_json("Parameter 'value' must not be empty if state=present and allow_no_value=False")
|
||||
|
||||
(changed, backup_file, diff, msg) = do_ini(module, path, section, option, value, state, backup, no_extra_spaces, create, allow_no_value)
|
||||
|
||||
@@ -59,8 +59,8 @@ options:
|
||||
executable:
|
||||
description:
|
||||
- The path to the C(7z) executable to use for extracting files from the ISO.
|
||||
- If not provided, it will assume the value C(7z).
|
||||
type: path
|
||||
default: '7z'
|
||||
notes:
|
||||
- Only the file checksum (content) is taken into account when extracting files
|
||||
from the ISO image. If C(force=no), only checks the presence of the file.
|
||||
@@ -101,7 +101,8 @@ def main():
|
||||
image=dict(type='path', required=True, aliases=['path', 'src']),
|
||||
dest=dict(type='path', required=True),
|
||||
files=dict(type='list', elements='str', required=True),
|
||||
force=dict(type='bool', default=True, aliases=['thirsty']),
|
||||
force=dict(type='bool', default=True, aliases=['thirsty'],
|
||||
deprecated_aliases=[dict(name='thirsty', version='3.0.0', collection_name='community.general')]),
|
||||
executable=dict(type='path'), # No default on purpose
|
||||
),
|
||||
supports_check_mode=True,
|
||||
@@ -112,10 +113,6 @@ def main():
|
||||
force = module.params['force']
|
||||
executable = module.params['executable']
|
||||
|
||||
if module.params.get('thirsty'):
|
||||
module.deprecate('The alias "thirsty" has been deprecated and will be removed, use "force" instead',
|
||||
version='3.0.0', collection_name='community.general') # was Ansible 2.13
|
||||
|
||||
result = dict(
|
||||
changed=False,
|
||||
dest=dest,
|
||||
|
||||
@@ -66,6 +66,7 @@ options:
|
||||
or a hash where the key is an element name and the value is the element value.
|
||||
- This parameter requires C(xpath) to be set.
|
||||
type: list
|
||||
elements: raw
|
||||
set_children:
|
||||
description:
|
||||
- Set the child-element(s) of a selected element for a given C(xpath).
|
||||
@@ -73,6 +74,7 @@ options:
|
||||
- Child elements must be specified as in C(add_children).
|
||||
- This parameter requires C(xpath) to be set.
|
||||
type: list
|
||||
elements: raw
|
||||
count:
|
||||
description:
|
||||
- Search for a given C(xpath) and provide the count of any matches.
|
||||
@@ -809,8 +811,8 @@ def main():
|
||||
state=dict(type='str', default='present', choices=['absent', 'present'], aliases=['ensure']),
|
||||
value=dict(type='raw'),
|
||||
attribute=dict(type='raw'),
|
||||
add_children=dict(type='list'),
|
||||
set_children=dict(type='list'),
|
||||
add_children=dict(type='list', elements='raw'),
|
||||
set_children=dict(type='list', elements='raw'),
|
||||
count=dict(type='bool', default=False),
|
||||
print_match=dict(type='bool', default=False),
|
||||
pretty_print=dict(type='bool', default=False),
|
||||
|
||||
1
plugins/modules/github_repo.py
Symbolic link
1
plugins/modules/github_repo.py
Symbolic link
@@ -0,0 +1 @@
|
||||
./source_control/github/github_repo.py
|
||||
1
plugins/modules/gitlab_project_members.py
Symbolic link
1
plugins/modules/gitlab_project_members.py
Symbolic link
@@ -0,0 +1 @@
|
||||
source_control/gitlab/gitlab_project_members.py
|
||||
@@ -137,6 +137,7 @@ options:
|
||||
aliases:
|
||||
- defaultRoles
|
||||
type: list
|
||||
elements: str
|
||||
|
||||
redirect_uris:
|
||||
description:
|
||||
@@ -145,6 +146,7 @@ options:
|
||||
aliases:
|
||||
- redirectUris
|
||||
type: list
|
||||
elements: str
|
||||
|
||||
web_origins:
|
||||
description:
|
||||
@@ -153,6 +155,7 @@ options:
|
||||
aliases:
|
||||
- webOrigins
|
||||
type: list
|
||||
elements: str
|
||||
|
||||
not_before:
|
||||
description:
|
||||
@@ -707,10 +710,10 @@ def main():
|
||||
enabled=dict(type='bool'),
|
||||
client_authenticator_type=dict(type='str', choices=['client-secret', 'client-jwt'], aliases=['clientAuthenticatorType']),
|
||||
secret=dict(type='str', no_log=True),
|
||||
registration_access_token=dict(type='str', aliases=['registrationAccessToken']),
|
||||
default_roles=dict(type='list', aliases=['defaultRoles']),
|
||||
redirect_uris=dict(type='list', aliases=['redirectUris']),
|
||||
web_origins=dict(type='list', aliases=['webOrigins']),
|
||||
registration_access_token=dict(type='str', aliases=['registrationAccessToken'], no_log=True),
|
||||
default_roles=dict(type='list', elements='str', aliases=['defaultRoles']),
|
||||
redirect_uris=dict(type='list', elements='str', aliases=['redirectUris']),
|
||||
web_origins=dict(type='list', elements='str', aliases=['webOrigins']),
|
||||
not_before=dict(type='int', aliases=['notBefore']),
|
||||
bearer_only=dict(type='bool', aliases=['bearerOnly']),
|
||||
consent_required=dict(type='bool', aliases=['consentRequired']),
|
||||
|
||||
@@ -34,6 +34,7 @@ description:
|
||||
options:
|
||||
search_terms:
|
||||
type: list
|
||||
elements: dict
|
||||
description:
|
||||
- A list of one or more search terms.
|
||||
- Each search term can either be a simple string or it can be a dictionary for more control.
|
||||
@@ -372,7 +373,7 @@ def main():
|
||||
master_password=dict(required=True, type='str', no_log=True),
|
||||
secret_key=dict(type='str', no_log=True),
|
||||
), default=None),
|
||||
search_terms=dict(required=True, type='list')
|
||||
search_terms=dict(required=True, type='list', elements='dict'),
|
||||
),
|
||||
supports_check_mode=True
|
||||
)
|
||||
|
||||
@@ -22,46 +22,56 @@ options:
|
||||
- The path to the bin directory of OpenDJ.
|
||||
required: false
|
||||
default: /opt/opendj/bin
|
||||
type: path
|
||||
hostname:
|
||||
description:
|
||||
- The hostname of the OpenDJ server.
|
||||
required: true
|
||||
type: str
|
||||
port:
|
||||
description:
|
||||
- The Admin port on which the OpenDJ instance is available.
|
||||
required: true
|
||||
type: str
|
||||
username:
|
||||
description:
|
||||
- The username to connect to.
|
||||
required: false
|
||||
default: cn=Directory Manager
|
||||
type: str
|
||||
password:
|
||||
description:
|
||||
- The password for the cn=Directory Manager user.
|
||||
- Either password or passwordfile is needed.
|
||||
required: false
|
||||
type: str
|
||||
passwordfile:
|
||||
description:
|
||||
- Location to the password file which holds the password for the cn=Directory Manager user.
|
||||
- Either password or passwordfile is needed.
|
||||
required: false
|
||||
type: path
|
||||
backend:
|
||||
description:
|
||||
- The name of the backend on which the property needs to be updated.
|
||||
required: true
|
||||
type: str
|
||||
name:
|
||||
description:
|
||||
- The configuration setting to update.
|
||||
required: true
|
||||
type: str
|
||||
value:
|
||||
description:
|
||||
- The value for the configuration item.
|
||||
required: true
|
||||
type: str
|
||||
state:
|
||||
description:
|
||||
- If configuration needs to be added/updated
|
||||
required: false
|
||||
default: "present"
|
||||
type: str
|
||||
'''
|
||||
|
||||
EXAMPLES = '''
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user