|
|
|
@ -4,14 +4,18 @@
|
|
|
|
|
# Copyright (c) 2017 F5 Networks Inc.
|
|
|
|
|
# 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'}
|
|
|
|
|
|
|
|
|
|
DOCUMENTATION = '''
|
|
|
|
|
DOCUMENTATION = r'''
|
|
|
|
|
---
|
|
|
|
|
module: bigip_qkview
|
|
|
|
|
short_description: Manage qkviews on the device.
|
|
|
|
|
short_description: Manage qkviews on the device
|
|
|
|
|
description:
|
|
|
|
|
- Manages creating and downloading qkviews from a BIG-IP. Various
|
|
|
|
|
options can be provided when creating qkviews. The qkview is important
|
|
|
|
@ -82,43 +86,44 @@ author:
|
|
|
|
|
- Tim Rupp (@caphrim007)
|
|
|
|
|
'''
|
|
|
|
|
|
|
|
|
|
EXAMPLES = '''
|
|
|
|
|
EXAMPLES = r'''
|
|
|
|
|
- name: Fetch a qkview from the remote device
|
|
|
|
|
bigip_qkview:
|
|
|
|
|
asm_request_log: "yes"
|
|
|
|
|
exclude:
|
|
|
|
|
- audit
|
|
|
|
|
- secure
|
|
|
|
|
dest: "/tmp/localhost.localdomain.qkview"
|
|
|
|
|
asm_request_log: yes
|
|
|
|
|
exclude:
|
|
|
|
|
- audit
|
|
|
|
|
- secure
|
|
|
|
|
dest: /tmp/localhost.localdomain.qkview
|
|
|
|
|
delegate_to: localhost
|
|
|
|
|
'''
|
|
|
|
|
|
|
|
|
|
RETURN = '''
|
|
|
|
|
RETURN = r'''
|
|
|
|
|
stdout:
|
|
|
|
|
description: The set of responses from the commands
|
|
|
|
|
returned: always
|
|
|
|
|
type: list
|
|
|
|
|
sample: ['...', '...']
|
|
|
|
|
description: The set of responses from the commands
|
|
|
|
|
returned: always
|
|
|
|
|
type: list
|
|
|
|
|
sample: ['...', '...']
|
|
|
|
|
stdout_lines:
|
|
|
|
|
description: The value of stdout split into a list
|
|
|
|
|
returned: always
|
|
|
|
|
type: list
|
|
|
|
|
sample: [['...', '...'], ['...'], ['...']]
|
|
|
|
|
description: The value of stdout split into a list
|
|
|
|
|
returned: always
|
|
|
|
|
type: list
|
|
|
|
|
sample: [['...', '...'], ['...'], ['...']]
|
|
|
|
|
'''
|
|
|
|
|
|
|
|
|
|
import re
|
|
|
|
|
import os
|
|
|
|
|
|
|
|
|
|
from ansible.module_utils.six import string_types
|
|
|
|
|
from ansible.module_utils.f5_utils import AnsibleF5Client
|
|
|
|
|
from ansible.module_utils.f5_utils import AnsibleF5Parameters
|
|
|
|
|
from ansible.module_utils.f5_utils import HAS_F5SDK
|
|
|
|
|
from ansible.module_utils.f5_utils import F5ModuleError
|
|
|
|
|
from distutils.version import LooseVersion
|
|
|
|
|
|
|
|
|
|
from ansible.module_utils.six import string_types
|
|
|
|
|
from ansible.module_utils.f5_utils import (
|
|
|
|
|
AnsibleF5Client,
|
|
|
|
|
AnsibleF5Parameters,
|
|
|
|
|
HAS_F5SDK,
|
|
|
|
|
F5ModuleError,
|
|
|
|
|
iControlUnexpectedHTTPError
|
|
|
|
|
)
|
|
|
|
|
try:
|
|
|
|
|
from ansible.module_utils.f5_utils import iControlUnexpectedHTTPError
|
|
|
|
|
except ImportError:
|
|
|
|
|
HAS_F5SDK = False
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class Parameters(AnsibleF5Parameters):
|
|
|
|
@ -397,17 +402,17 @@ class ArgumentSpec(object):
|
|
|
|
|
),
|
|
|
|
|
asm_request_log=dict(
|
|
|
|
|
type='bool',
|
|
|
|
|
default=False,
|
|
|
|
|
default='no',
|
|
|
|
|
),
|
|
|
|
|
max_file_size=dict(
|
|
|
|
|
type='int',
|
|
|
|
|
),
|
|
|
|
|
complete_information=dict(
|
|
|
|
|
default=False,
|
|
|
|
|
default='no',
|
|
|
|
|
type='bool'
|
|
|
|
|
),
|
|
|
|
|
exclude_core=dict(
|
|
|
|
|
default=False,
|
|
|
|
|
default="no",
|
|
|
|
|
type='bool'
|
|
|
|
|
),
|
|
|
|
|
force=dict(
|
|
|
|
|