diff --git a/contrib/inventory/cloudstack.py b/contrib/inventory/cloudstack.py index bbebcacd92..db0322cfd6 100755 --- a/contrib/inventory/cloudstack.py +++ b/contrib/inventory/cloudstack.py @@ -70,7 +70,8 @@ based on the data obtained from CloudStack API: usage: cloudstack.py [--list] [--host HOST] [--project PROJECT] [--domain DOMAIN] """ -from __future__ import print_function +from __future__ import absolute_import, division, print_function +__metaclass__ = type import sys import argparse diff --git a/lib/ansible/module_utils/exoscale.py b/lib/ansible/module_utils/exoscale.py index abc9f95d79..e56f27144f 100644 --- a/lib/ansible/module_utils/exoscale.py +++ b/lib/ansible/module_utils/exoscale.py @@ -2,6 +2,9 @@ # Copyright (c) 2016, René Moser # Simplified BSD License (see licenses/simplified_bsd.txt or https://opensource.org/licenses/BSD-2-Clause) +from __future__ import absolute_import, division, print_function +__metaclass__ = type + import os from ansible.module_utils.six.moves import configparser diff --git a/lib/ansible/modules/cloud/cloudstack/_cs_zone_facts.py b/lib/ansible/modules/cloud/cloudstack/_cs_zone_facts.py index c7a6cccd9c..91abf23fbe 100644 --- a/lib/ansible/modules/cloud/cloudstack/_cs_zone_facts.py +++ b/lib/ansible/modules/cloud/cloudstack/_cs_zone_facts.py @@ -4,6 +4,9 @@ # Copyright (c) 2016, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['deprecated'], 'supported_by': 'community'} @@ -23,12 +26,12 @@ deprecated: version_added: '2.1' author: René Moser (@resmo) options: - name: + zone: description: - Name of the zone. type: str required: true - aliases: [ zone ] + aliases: [ name ] extends_documentation_fragment: cloudstack ''' diff --git a/lib/ansible/modules/cloud/cloudstack/cs_account.py b/lib/ansible/modules/cloud/cloudstack/cs_account.py index 66d430d9a6..3f3c50b805 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_account.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_account.py @@ -4,6 +4,9 @@ # (c) 2015, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_affinitygroup.py b/lib/ansible/modules/cloud/cloudstack/cs_affinitygroup.py index d8d2c7e17f..3e57d1e208 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_affinitygroup.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_affinitygroup.py @@ -4,6 +4,9 @@ # (c) 2015, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} @@ -27,7 +30,6 @@ options: description: - Type of the affinity group. If not specified, first found affinity type is used. type: str - aliases: [ affinty_type ] description: description: - Description of the affinity group. @@ -143,7 +145,7 @@ class AnsibleCloudStackAffinityGroup(AnsibleCloudStack): return self.affinity_group def get_affinity_type(self): - affinity_type = self.module.params.get('affinity_type') or self.module.params.get('affinty_type') + affinity_type = self.module.params.get('affinity_type') affinity_types = self.query_api('listAffinityGroupTypes', ) if affinity_types: @@ -200,7 +202,6 @@ def main(): argument_spec = cs_argument_spec() argument_spec.update(dict( name=dict(required=True), - affinty_type=dict(removed_in_version='2.9'), affinity_type=dict(), description=dict(), state=dict(choices=['present', 'absent'], default='present'), @@ -213,9 +214,6 @@ def main(): module = AnsibleModule( argument_spec=argument_spec, required_together=cs_required_together(), - mutually_exclusive=( - ['affinity_type', 'affinty_type'], - ), supports_check_mode=True ) diff --git a/lib/ansible/modules/cloud/cloudstack/cs_cluster.py b/lib/ansible/modules/cloud/cloudstack/cs_cluster.py index f171fbe846..e1ee3b1c55 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_cluster.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_cluster.py @@ -4,6 +4,9 @@ # (c) 2016, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_configuration.py b/lib/ansible/modules/cloud/cloudstack/cs_configuration.py index b227bbd38a..79e01990f1 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_configuration.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_configuration.py @@ -4,6 +4,9 @@ # (c) 2016, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_domain.py b/lib/ansible/modules/cloud/cloudstack/cs_domain.py index 8eb50ccd93..125fb5ee81 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_domain.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_domain.py @@ -4,6 +4,9 @@ # (c) 2015, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_facts.py b/lib/ansible/modules/cloud/cloudstack/cs_facts.py index 5e9d9b631b..12d4397d3e 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_facts.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_facts.py @@ -4,6 +4,9 @@ # (c) 2015, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_firewall.py b/lib/ansible/modules/cloud/cloudstack/cs_firewall.py index 84ff5a3cfa..08a26b8e4d 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_firewall.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_firewall.py @@ -4,6 +4,9 @@ # Copyright: (c) 2015, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], diff --git a/lib/ansible/modules/cloud/cloudstack/cs_host.py b/lib/ansible/modules/cloud/cloudstack/cs_host.py index ca63511c3f..ca0b07d392 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_host.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_host.py @@ -4,6 +4,9 @@ # (c) 2016, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_image_store.py b/lib/ansible/modules/cloud/cloudstack/cs_image_store.py index aa04be71d1..f54bba2e1b 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_image_store.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_image_store.py @@ -3,6 +3,9 @@ # Copyright: (c) 2019, Patryk Cichy @PatTheSilent # 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 + ANSIBLE_METADATA = { 'metadata_version': '1.1', 'status': ['preview'], diff --git a/lib/ansible/modules/cloud/cloudstack/cs_instance_nic.py b/lib/ansible/modules/cloud/cloudstack/cs_instance_nic.py index d580ff1a35..69f45d0445 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_instance_nic.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_instance_nic.py @@ -5,6 +5,9 @@ # (c) 2017, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_instance_nic_secondaryip.py b/lib/ansible/modules/cloud/cloudstack/cs_instance_nic_secondaryip.py index c840b8ea9d..a122e1994b 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_instance_nic_secondaryip.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_instance_nic_secondaryip.py @@ -4,6 +4,9 @@ # (c) 2017, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_instancegroup.py b/lib/ansible/modules/cloud/cloudstack/cs_instancegroup.py index 83663143fc..997633a2c6 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_instancegroup.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_instancegroup.py @@ -4,6 +4,9 @@ # (c) 2015, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_ip_address.py b/lib/ansible/modules/cloud/cloudstack/cs_ip_address.py index ff41ea5eed..4d6b821a0c 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_ip_address.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_ip_address.py @@ -5,6 +5,9 @@ # Copyright (c) 2015, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_iso.py b/lib/ansible/modules/cloud/cloudstack/cs_iso.py index 76cd9ff0dd..5781a0ce06 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_iso.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_iso.py @@ -4,6 +4,9 @@ # (c) 2015, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_loadbalancer_rule.py b/lib/ansible/modules/cloud/cloudstack/cs_loadbalancer_rule.py index 817fa6c042..702c20da47 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_loadbalancer_rule.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_loadbalancer_rule.py @@ -5,6 +5,9 @@ # (c) 2015, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_loadbalancer_rule_member.py b/lib/ansible/modules/cloud/cloudstack/cs_loadbalancer_rule_member.py index a680a532b0..8a9249eecc 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_loadbalancer_rule_member.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_loadbalancer_rule_member.py @@ -5,6 +5,9 @@ # Copyright (c) 2015, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_network.py b/lib/ansible/modules/cloud/cloudstack/cs_network.py index b1d4a0ed35..8231881e24 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_network.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_network.py @@ -4,6 +4,8 @@ # Copyright (c) 2017, René Moser # 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 ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], @@ -78,6 +80,7 @@ options: - The gateway of the IPv6 network. - Required for shared networks. - Only considered on create. + type: str vlan: description: - The ID or VID of the network. diff --git a/lib/ansible/modules/cloud/cloudstack/cs_network_acl.py b/lib/ansible/modules/cloud/cloudstack/cs_network_acl.py index a38102fb56..debb767741 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_network_acl.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_network_acl.py @@ -4,6 +4,9 @@ # (c) 2017, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_network_acl_rule.py b/lib/ansible/modules/cloud/cloudstack/cs_network_acl_rule.py index 8e1d5d0907..2300e80dc2 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_network_acl_rule.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_network_acl_rule.py @@ -4,6 +4,9 @@ # Copyright (c) 2017, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_network_offering.py b/lib/ansible/modules/cloud/cloudstack/cs_network_offering.py index d6f70a1932..9677ead4c7 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_network_offering.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_network_offering.py @@ -5,6 +5,9 @@ # Copyright (c) 2017, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_physical_network.py b/lib/ansible/modules/cloud/cloudstack/cs_physical_network.py index da4a6b67f4..a7b2e05a68 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_physical_network.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_physical_network.py @@ -4,6 +4,9 @@ # (c) 2017, Netservers Ltd. # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_pod.py b/lib/ansible/modules/cloud/cloudstack/cs_pod.py index 5b53368435..141491e89b 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_pod.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_pod.py @@ -4,6 +4,8 @@ # Copyright (c) 2016, René Moser # 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 ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], diff --git a/lib/ansible/modules/cloud/cloudstack/cs_project.py b/lib/ansible/modules/cloud/cloudstack/cs_project.py index 3647eb3229..509b30aa04 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_project.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_project.py @@ -4,6 +4,9 @@ # (c) 2015, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_region.py b/lib/ansible/modules/cloud/cloudstack/cs_region.py index 065d89f930..6ff481fc87 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_region.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_region.py @@ -4,6 +4,9 @@ # (c) 2016, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_resourcelimit.py b/lib/ansible/modules/cloud/cloudstack/cs_resourcelimit.py index 509dcc30c5..ea354065cb 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_resourcelimit.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_resourcelimit.py @@ -4,6 +4,9 @@ # Copyright (c) 2016, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_role.py b/lib/ansible/modules/cloud/cloudstack/cs_role.py index 001cdf924f..6db295bd81 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_role.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_role.py @@ -4,6 +4,9 @@ # (c) 2016, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} @@ -23,12 +26,12 @@ options: - Name of the role. type: str required: true - id: + uuid: description: - ID of the role. - - If provided, I(id) is used as key. + - If provided, I(uuid) is used as key. type: str - aliases: [ uuid ] + aliases: [ id ] role_type: description: - Type of the role. diff --git a/lib/ansible/modules/cloud/cloudstack/cs_role_permission.py b/lib/ansible/modules/cloud/cloudstack/cs_role_permission.py index 16cbb3442c..30392b2f87 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_role_permission.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_role_permission.py @@ -4,6 +4,9 @@ # Copyright (c) 2017, David Passante (@dpassante) # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_router.py b/lib/ansible/modules/cloud/cloudstack/cs_router.py index 496d28e562..db4240a7b8 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_router.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_router.py @@ -4,6 +4,9 @@ # (c) 2016, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_sshkeypair.py b/lib/ansible/modules/cloud/cloudstack/cs_sshkeypair.py index 4b7547b2f5..f36fedf576 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_sshkeypair.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_sshkeypair.py @@ -4,6 +4,9 @@ # (c) 2015, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_staticnat.py b/lib/ansible/modules/cloud/cloudstack/cs_staticnat.py index 8b9ff17484..42fb603d58 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_staticnat.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_staticnat.py @@ -4,6 +4,9 @@ # Copyright (c) 2015, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_storage_pool.py b/lib/ansible/modules/cloud/cloudstack/cs_storage_pool.py index 9b59c94f7b..e7c310eaeb 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_storage_pool.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_storage_pool.py @@ -5,6 +5,9 @@ # (c) 2017, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_template.py b/lib/ansible/modules/cloud/cloudstack/cs_template.py index 961c54d027..d75b6307de 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_template.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_template.py @@ -4,6 +4,9 @@ # Copyright (c) 2015, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_traffic_type.py b/lib/ansible/modules/cloud/cloudstack/cs_traffic_type.py index 4443fb161a..87c2e199f3 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_traffic_type.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_traffic_type.py @@ -4,6 +4,8 @@ # (c) 2019, Patryk D. Cichy # 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 ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], diff --git a/lib/ansible/modules/cloud/cloudstack/cs_user.py b/lib/ansible/modules/cloud/cloudstack/cs_user.py index 1b50f203ea..79342c7223 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_user.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_user.py @@ -4,6 +4,8 @@ # Copyright (c) 2015, René Moser # 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 ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], diff --git a/lib/ansible/modules/cloud/cloudstack/cs_vlan_ip_range.py b/lib/ansible/modules/cloud/cloudstack/cs_vlan_ip_range.py index 6e8f0e02ad..b83a45d7b3 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_vlan_ip_range.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_vlan_ip_range.py @@ -4,6 +4,8 @@ # Copyright (c) 2018, David Passante <@dpassante> # 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 ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], diff --git a/lib/ansible/modules/cloud/cloudstack/cs_vmsnapshot.py b/lib/ansible/modules/cloud/cloudstack/cs_vmsnapshot.py index 6badf3811b..47eed8fcd7 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_vmsnapshot.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_vmsnapshot.py @@ -4,6 +4,9 @@ # (c) 2015, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_volume.py b/lib/ansible/modules/cloud/cloudstack/cs_volume.py index 7d4a17a7c8..3d4a0d1691 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_volume.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_volume.py @@ -5,6 +5,9 @@ # (c) 2015, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_vpc_offering.py b/lib/ansible/modules/cloud/cloudstack/cs_vpc_offering.py index 283401d4de..e0dabdef72 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_vpc_offering.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_vpc_offering.py @@ -4,6 +4,9 @@ # Copyright (c) 2017, David Passante (@dpassante) # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_vpn_connection.py b/lib/ansible/modules/cloud/cloudstack/cs_vpn_connection.py index 62eb8a78ea..cdcc249118 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_vpn_connection.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_vpn_connection.py @@ -7,7 +7,6 @@ from __future__ import absolute_import, division, print_function __metaclass__ = type - ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_vpn_customer_gateway.py b/lib/ansible/modules/cloud/cloudstack/cs_vpn_customer_gateway.py index 7a43c198b6..2c14a9fcea 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_vpn_customer_gateway.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_vpn_customer_gateway.py @@ -7,7 +7,6 @@ from __future__ import absolute_import, division, print_function __metaclass__ = type - ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_vpn_gateway.py b/lib/ansible/modules/cloud/cloudstack/cs_vpn_gateway.py index 3bfa3b75d1..72bac2beba 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_vpn_gateway.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_vpn_gateway.py @@ -4,6 +4,9 @@ # (c) 2017, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} diff --git a/lib/ansible/modules/cloud/cloudstack/cs_zone.py b/lib/ansible/modules/cloud/cloudstack/cs_zone.py index 00a959686d..4aa933c78a 100644 --- a/lib/ansible/modules/cloud/cloudstack/cs_zone.py +++ b/lib/ansible/modules/cloud/cloudstack/cs_zone.py @@ -4,6 +4,9 @@ # (c) 2016, René Moser # 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 + ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'community'} diff --git a/lib/ansible/plugins/doc_fragments/cloudstack.py b/lib/ansible/plugins/doc_fragments/cloudstack.py index dc0ef549e5..7e93e6cbdc 100644 --- a/lib/ansible/plugins/doc_fragments/cloudstack.py +++ b/lib/ansible/plugins/doc_fragments/cloudstack.py @@ -3,6 +3,9 @@ # Copyright (c) 2015, René Moser # 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 + class ModuleDocFragment(object): diff --git a/lib/ansible/plugins/doc_fragments/exoscale.py b/lib/ansible/plugins/doc_fragments/exoscale.py index 89073da5ee..32719807b7 100644 --- a/lib/ansible/plugins/doc_fragments/exoscale.py +++ b/lib/ansible/plugins/doc_fragments/exoscale.py @@ -3,6 +3,9 @@ # Copyright: (c) 2017, René Moser # 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 + class ModuleDocFragment(object): diff --git a/test/sanity/ignore.txt b/test/sanity/ignore.txt index 4e9cb251af..4e1ca07768 100644 --- a/test/sanity/ignore.txt +++ b/test/sanity/ignore.txt @@ -10,8 +10,6 @@ contrib/inventory/brook.py future-import-boilerplate contrib/inventory/brook.py metaclass-boilerplate contrib/inventory/cloudforms.py future-import-boilerplate contrib/inventory/cloudforms.py metaclass-boilerplate -contrib/inventory/cloudstack.py future-import-boilerplate -contrib/inventory/cloudstack.py metaclass-boilerplate contrib/inventory/cobbler.py future-import-boilerplate contrib/inventory/cobbler.py metaclass-boilerplate contrib/inventory/collins.py future-import-boilerplate @@ -220,8 +218,6 @@ lib/ansible/module_utils/distro/_distro.py no-assert lib/ansible/module_utils/distro/_distro.py pep8!skip # bundled code we don't want to modify lib/ansible/module_utils/ec2.py future-import-boilerplate lib/ansible/module_utils/ec2.py metaclass-boilerplate -lib/ansible/module_utils/exoscale.py future-import-boilerplate -lib/ansible/module_utils/exoscale.py metaclass-boilerplate lib/ansible/module_utils/f5_utils.py future-import-boilerplate lib/ansible/module_utils/f5_utils.py metaclass-boilerplate lib/ansible/module_utils/facts/__init__.py empty-init # breaks namespacing, deprecate and eventually remove @@ -1303,92 +1299,6 @@ lib/ansible/modules/cloud/centurylink/clc_server.py validate-modules:doc-missing lib/ansible/modules/cloud/centurylink/clc_server_snapshot.py validate-modules:implied-parameter-type-mismatch lib/ansible/modules/cloud/centurylink/clc_server_snapshot.py validate-modules:parameter-type-not-in-doc lib/ansible/modules/cloud/centurylink/clc_server_snapshot.py validate-modules:doc-missing-type -lib/ansible/modules/cloud/cloudstack/cs_account.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_account.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_affinitygroup.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_affinitygroup.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_affinitygroup.py validate-modules:doc-missing-type -lib/ansible/modules/cloud/cloudstack/cs_cluster.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_cluster.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_configuration.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_configuration.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_domain.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_domain.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_facts.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_facts.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_firewall.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_firewall.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_host.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_host.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_image_store.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_image_store.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_instance_nic.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_instance_nic.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_instance_nic_secondaryip.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_instance_nic_secondaryip.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_instancegroup.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_instancegroup.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_ip_address.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_ip_address.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_iso.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_iso.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_loadbalancer_rule.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_loadbalancer_rule.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_loadbalancer_rule_member.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_loadbalancer_rule_member.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_network.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_network.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_network.py validate-modules:doc-missing-type -lib/ansible/modules/cloud/cloudstack/cs_network_acl.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_network_acl.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_network_acl_rule.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_network_acl_rule.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_network_offering.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_network_offering.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_physical_network.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_physical_network.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_pod.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_pod.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_project.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_project.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_region.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_region.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_resourcelimit.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_resourcelimit.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_role.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_role.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_role.py validate-modules:doc-missing-type -lib/ansible/modules/cloud/cloudstack/cs_role_permission.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_role_permission.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_router.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_router.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_sshkeypair.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_sshkeypair.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_staticnat.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_staticnat.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_storage_pool.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_storage_pool.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_template.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_template.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_traffic_type.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_traffic_type.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_user.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_user.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_vlan_ip_range.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_vlan_ip_range.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_vmsnapshot.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_vmsnapshot.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_volume.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_volume.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_vpc_offering.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_vpc_offering.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_vpn_gateway.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_vpn_gateway.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_zone.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/cs_zone.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/_cs_zone_facts.py future-import-boilerplate -lib/ansible/modules/cloud/cloudstack/_cs_zone_facts.py metaclass-boilerplate -lib/ansible/modules/cloud/cloudstack/_cs_zone_facts.py validate-modules:doc-missing-type lib/ansible/modules/cloud/digital_ocean/_digital_ocean.py validate-modules:undocumented-parameter lib/ansible/modules/cloud/digital_ocean/_digital_ocean.py validate-modules:parameter-type-not-in-doc lib/ansible/modules/cloud/digital_ocean/_digital_ocean.py validate-modules:doc-missing-type @@ -5798,8 +5708,6 @@ lib/ansible/plugins/doc_fragments/checkpoint_commands.py future-import-boilerpla lib/ansible/plugins/doc_fragments/checkpoint_commands.py metaclass-boilerplate lib/ansible/plugins/doc_fragments/checkpoint_objects.py future-import-boilerplate lib/ansible/plugins/doc_fragments/checkpoint_objects.py metaclass-boilerplate -lib/ansible/plugins/doc_fragments/cloudstack.py future-import-boilerplate -lib/ansible/plugins/doc_fragments/cloudstack.py metaclass-boilerplate lib/ansible/plugins/doc_fragments/cnos.py future-import-boilerplate lib/ansible/plugins/doc_fragments/cnos.py metaclass-boilerplate lib/ansible/plugins/doc_fragments/constructed.py future-import-boilerplate @@ -5828,8 +5736,6 @@ lib/ansible/plugins/doc_fragments/enos.py future-import-boilerplate lib/ansible/plugins/doc_fragments/enos.py metaclass-boilerplate lib/ansible/plugins/doc_fragments/eos.py future-import-boilerplate lib/ansible/plugins/doc_fragments/eos.py metaclass-boilerplate -lib/ansible/plugins/doc_fragments/exoscale.py future-import-boilerplate -lib/ansible/plugins/doc_fragments/exoscale.py metaclass-boilerplate lib/ansible/plugins/doc_fragments/f5.py future-import-boilerplate lib/ansible/plugins/doc_fragments/f5.py metaclass-boilerplate lib/ansible/plugins/doc_fragments/files.py future-import-boilerplate @@ -6280,8 +6186,6 @@ test/units/modules/cloud/amazon/test_route53_zone.py future-import-boilerplate test/units/modules/cloud/amazon/test_route53_zone.py metaclass-boilerplate test/units/modules/cloud/amazon/test_s3_bucket_notification.py future-import-boilerplate test/units/modules/cloud/amazon/test_s3_bucket_notification.py metaclass-boilerplate -test/units/modules/cloud/cloudstack/test_cs_traffic_type.py future-import-boilerplate -test/units/modules/cloud/cloudstack/test_cs_traffic_type.py metaclass-boilerplate test/units/modules/cloud/google/test_gce_tag.py future-import-boilerplate test/units/modules/cloud/google/test_gce_tag.py metaclass-boilerplate test/units/modules/cloud/google/test_gcp_forwarding_rule.py future-import-boilerplate diff --git a/test/units/modules/cloud/cloudstack/test_cs_traffic_type.py b/test/units/modules/cloud/cloudstack/test_cs_traffic_type.py index 007237e8d1..d164b59661 100644 --- a/test/units/modules/cloud/cloudstack/test_cs_traffic_type.py +++ b/test/units/modules/cloud/cloudstack/test_cs_traffic_type.py @@ -1,3 +1,6 @@ +from __future__ import absolute_import, division, print_function +__metaclass__ = type + import sys import pytest