Anons79 Mini Shell

Directory : /lib/python2.7/site-packages/ansible/modules/network/f5/
Upload File :
Current File : //lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyo

�
�Udac@`s�ddlmZmZmZeZidd6dgd6dd6ZdZd	Zd
Z	ddl
mZddl
mZdd
l
mZddl
mZddlmZy�ddlmZddlmZddlmZddlmZddlmZddlmZddlmZddlmZddlmZWn�ek
r�ddl mZddl!mZddl!mZddl!mZddl!mZddl!mZddl"mZddl"mZddl#mZnXdefd��YZ$de$fd��YZ%de$fd��YZ&de$fd ��YZ'd!e'fd"��YZ(d#e'fd$��YZ)d%e*fd&��YZ+d'e*fd(��YZ,d)e*fd*��YZ-d+�Z.e/d,kr�e.�nd-S(.i(tabsolute_importtdivisiontprint_functions1.1tmetadata_versiontpreviewtstatust	certifiedtsupported_bys{
---
module: bigip_virtual_address
short_description: Manage LTM virtual addresses on a BIG-IP
description:
  - Manage LTM virtual addresses on a BIG-IP.
version_added: 2.4
options:
  name:
    description:
      - Name of the virtual address.
      - If this parameter is not provided, then the value of C(address) will
        be used.
    type: str
    version_added: 2.6
  address:
    description:
      - Virtual address. This value cannot be modified after it is set.
      - If you never created a virtual address, but did create virtual servers, then
        a virtual address for each virtual server was created automatically. The name
        of this virtual address is its IP address value.
    type: str
  netmask:
    description:
      - Netmask of the provided virtual address. This value cannot be
        modified after it is set.
      - When creating a new virtual address, if this parameter is not specified, the
        default value is C(255.255.255.255) for IPv4 addresses and
        C(ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff) for IPv6 addresses.
    type: str
  connection_limit:
    description:
      - Specifies the number of concurrent connections that the system
        allows on this virtual address.
    type: int
  arp_state:
    description:
      - Specifies whether the system accepts ARP requests. When (disabled),
        specifies that the system does not accept ARP requests. Note that
        both ARP and ICMP Echo must be disabled in order for forwarding
        virtual servers using that virtual address to forward ICMP packets.
        If (enabled), then the packets are dropped.
      - Deprecated. Use the C(arp) parameter instead.
      - When creating a new virtual address, if this parameter is not specified,
        the default value is C(enabled).
    type: str
    choices:
      - enabled
      - disabled
  arp:
    description:
      - Specifies whether the system accepts ARP requests.
      - When C(no), specifies that the system does not accept ARP requests.
      - When C(yes), then the packets are dropped.
      - Note that both ARP and ICMP Echo must be disabled in order for forwarding
        virtual servers using that virtual address to forward ICMP packets.
      - When creating a new virtual address, if this parameter is not specified,
        the default value is C(yes).
    type: bool
    version_added: 2.7
  auto_delete:
    description:
      - Specifies whether the system automatically deletes the virtual
        address with the deletion of the last associated virtual server.
        When C(disabled), specifies that the system leaves the virtual
        address even when all associated virtual servers have been deleted.
        When creating the virtual address, the default value is C(enabled).
      - C(enabled) and C(disabled) are deprecated and will be removed in
        Ansible 2.11. Instead, use known Ansible booleans such as C(yes) and
        C(no)
    type: str
  icmp_echo:
    description:
      - Specifies how the systems sends responses to (ICMP) echo requests
        on a per-virtual address basis for enabling route advertisement.
        When C(enabled), the BIG-IP system intercepts ICMP echo request
        packets and responds to them directly. When C(disabled), the BIG-IP
        system passes ICMP echo requests through to the backend servers.
        When (selective), causes the BIG-IP system to internally enable or
        disable responses based on virtual server state; C(when_any_available),
        C(when_all_available, or C(always), regardless of the state of any
        virtual servers.
    type: str
    choices:
      - enabled
      - disabled
      - selective
  state:
    description:
      - The virtual address state. If C(absent), an attempt to delete the
        virtual address will be made. This will only succeed if this
        virtual address is not in use by a virtual server. C(present) creates
        the virtual address and enables it. If C(enabled), enable the virtual
        address if it exists. If C(disabled), create the virtual address if
        needed, and set state to C(disabled).
    type: str
    choices:
      - present
      - absent
      - enabled
      - disabled
    default: present
  availability_calculation:
    description:
      - Specifies what routes of the virtual address the system advertises.
        When C(when_any_available), advertises the route when any virtual
        server is available. When C(when_all_available), advertises the
        route when all virtual servers are available. When (always), always
        advertises the route regardless of the virtual servers available.
    type: str
    choices:
      - always
      - when_all_available
      - when_any_available
    aliases: ['advertise_route']
    version_added: 2.6
  route_advertisement:
    description:
      - Specifies whether the system uses route advertisement for this
        virtual address.
      - When disabled, the system does not advertise routes for this virtual address.
      - The majority of these options are only supported on versions 13.0.0-HF1 or
        higher. On versions less than this, all choices expect C(disabled) will
        translate to C(enabled).
      - When C(always), the BIG-IP system will always advertise the route for the
        virtual address, regardless of availability status. This requires an C(enabled)
        virtual address.
      - When C(enabled), the BIG-IP system will advertise the route for the available
        virtual address, based on the calculation method in the availability calculation.
      - When C(disabled), the BIG-IP system will not advertise the route for the virtual
        address, regardless of the availability status.
      - When C(selective), you can also selectively enable ICMP echo responses, which
        causes the BIG-IP system to internally enable or disable responses based on
        virtual server state. Either C(any) virtual server, C(all) virtual servers, or
        C(always), regardless of the state of any virtual server.
      - When C(any), the BIG-IP system will advertise the route for the virtual address
        when any virtual server is available.
      - When C(all), the BIG-IP system will advertise the route for the virtual address
        when all virtual servers are available.
    type: str
    choices:
      - disabled
      - enabled
      - always
      - selective
      - any
      - all
    version_added: 2.6
  partition:
    description:
      - Device partition to manage resources on.
    type: str
    default: Common
    version_added: 2.5
  traffic_group:
    description:
      - The traffic group for the virtual address. When creating a new address,
        if this value is not specified, the default of C(/Common/traffic-group-1)
        will be used.
    type: str
    version_added: 2.5
  route_domain:
    description:
      - The route domain of the C(address) that you want to use.
      - This value cannot be modified after it is set.
    type: str
    version_added: 2.6
  spanning:
    description:
      - Enables all BIG-IP systems in a device group to listen for and process traffic
        on the same virtual address.
      - Spanning for a virtual address occurs when you enable the C(spanning) option on a
        device and then sync the virtual address to the other members of the device group.
      - Spanning also relies on the upstream router to distribute application flows to the
        BIG-IP systems using ECMP routes. ECMP defines a route to the virtual address using
        distinct Floating self-IP addresses configured on each BIG-IP system.
      - You must also configure MAC masquerade addresses and disable C(arp) on the virtual
        address when Spanning is enabled.
      - When creating a new virtual address, if this parameter is not specified, the default
        valus is C(no).
    version_added: 2.7
    type: bool
extends_documentation_fragment: f5
author:
  - Tim Rupp (@caphrim007)
  - Wojciech Wypior (@wojtek0806)
s�
- name: Add virtual address
  bigip_virtual_address:
    state: present
    partition: Common
    address: 10.10.10.10
    provider:
      server: lb.mydomain.net
      user: admin
      password: secret
  delegate_to: localhost

- name: Enable route advertisement on the virtual address
  bigip_virtual_address:
    state: present
    address: 10.10.10.10
    route_advertisement: any
    provider:
      server: lb.mydomain.net
      user: admin
      password: secret
  delegate_to: localhost
sI
availability_calculation:
  description: Specifies what routes of the virtual address the system advertises.
  returned: changed
  type: str
  sample: always
auto_delete:
  description: New setting for auto deleting virtual address.
  returned: changed
  type: str
  sample: enabled
icmp_echo:
  description: New ICMP echo setting applied to virtual address.
  returned: changed
  type: str
  sample: disabled
connection_limit:
  description: The new connection limit of the virtual address.
  returned: changed
  type: int
  sample: 1000
netmask:
  description: The netmask of the virtual address.
  returned: created
  type: int
  sample: 2345
arp:
  description: The new way the virtual address handles ARP requests.
  returned: changed
  type: bool
  sample: yes
address:
  description: The address of the virtual address.
  returned: created
  type: int
  sample: 2345
state:
  description: The new state of the virtual address.
  returned: changed
  type: str
  sample: disabled
spanning:
  description: Whether spanning is enabled or not
  returned: changed
  type: str
  sample: disabled
(t
AnsibleModule(tenv_fallback(t
BOOLEANS_TRUE(tBOOLEANS_FALSE(tLooseVersion(tF5RestClient(t
F5ModuleError(tAnsibleF5Parameters(ttransform_name(tfq_name(tf5_argument_spec(tis_valid_ip(tcompress_address(ttmos_versiont
ParameterscB`s;eZidd6dd6dd6dd6dd	6d
d6dd
6Zdddddddddg	Zddddd
dddddddgZddddddddd	d
dd	gZed��Zed��Zed��Z	ed��Z
ed��Zed��Zed��Z
ed��Zed��ZRS(troute_advertisement_typetrouteAdvertisementtauto_deletet
autoDeletet	icmp_echoticmpEchotconnection_limittconnectionLimittavailability_calculationtserverScopetnetmasktmaskt
traffic_groupttrafficGrouptarptenabledtspanningtaddresststatetroute_domaintadvertiseRoutecC`s`|jddkrdS|jddkr.dS|jdd	krEdS|jdd
kr\dSdS(NRtanytwhen_any_availabletalltwhen_all_availabletnonetalways(sanyR-(sallR/(R0salways(t_valuestNone(tself((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyRdscC`s(|jddkrdSt|jd�S(NR(R2R3tint(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyRoscC`sd|jddkrdS|jdtkr.dS|jddkrEdS|jdtkr\dSdSdS(NR)R&tpresenttyestdisabledtno(senabledspresent(R2R
RR3(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR&uscC`sE|jddkrdSt|jd�r5|jdStd��dS(NR!s0The provided 'netmask' is not a valid IP address(R2R3RR(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR!�scC`sM|jddkrdS|jdtkr.tS|jddkrEtStSdS(NRR&(R2R3R
tTruetFalse(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR�scC`sH|jdkr&|jddkr&dS|jdkr9dS|jdSdS(NR7R)R6R&R9R8(R&R2(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR)�s
"cC`sS|jddkrdSt|j|jd�}|jd�rC|Std��dS(NR#s/Common/s(Traffic groups can only exist in /Common(R2R3Rt	partitiont
startswithR(R4tresult((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR#�scC`s|jr|jS|jdSdS(NR(troute_advertisementR2(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR�s	cC`sk|jddkrdSt|j�}t|�td�kr\|jddkrUdSdSn|jdSdS(NR?s13.0.0R8R&(R2R3RtclientR(R4tversion((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR?�s(t__name__t
__module__tapi_mapt
updatablestreturnablestapi_attributestpropertyRRR&R!RR)R#RR?(((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR/sd
			
	
t
ApiParameterscB`s&eZed��Zed��ZRS(cC`s2|jddkrdS|jddkr.tStS(NR%R&(R2R3R:R;(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR%�s
cC`s2|jddkrdS|jddkr.tStS(NR'R&(R2R3R:R;(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR'�s
(RBRCRHR%R'(((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyRI�stModuleParameterscB`sSeZed��Zed��Zed��Zed��Zed��ZRS(cC`s]|jddkrN|jr/|jdkr/tS|jrY|jdkrYtSn|jdSdS(NR%R&R8(R2R3t	arp_stateR:R;(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR%�scC`sK|jddkrdSt|jd�r;t|jd�Std��dS(NR(s0The provided 'address' is not a valid IP address(R2R3RRR(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR(�scC`s,|jdk	r%dj|j|j�S|jS(Ns{0}%{1}(R*R3tformatR((R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pytfull_address�scC`sW|jddkrFt|j�}|jrSdj||j�}qSn
|jd}|S(Ntnames{0}%{1}(R2R3tstrR(R*RL(R4R>((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyRN�s	
cC`s|jddkrdSyt|jd�SWn�tk
r	dj|jjd|jjdt|jd|jd��}|jjj	|�}y|j
�}Wntk
r�td��nX|jdks�d|kr�|ddkr�td��nt|d	�SXdS(
NR*s,https://{0}:{1}/mgmt/tm/net/route-domain/{2}tservertserver_portR<s+The specified 'route_domain' was not found.i�tcodetid(
R2R3R5t
ValueErrorRLR@tproviderRtapitgettjsonRR(R4turitresptresponse((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR*�s&


 

+(RBRCRHR%R(RMRNR*(((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyRJ�s


tChangescB`seZd�ZRS(cC`sXi}y:x$|jD]}t||�||<qW|j|�}Wntk
rSnX|S(N(RFtgetattrt_filter_paramst	Exception(R4R>t
returnable((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyt	to_returns
(RBRCRa(((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR\st
UsableChangescB`s5eZed��Zed��Zed��ZRS(cC`sU|jddkrdS|jddkr5|jdSdj|jd|j�}|S(NR(R*s{0}%{1}(R2R3RLR*(R4R>((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR(#scC`sI|jddkrdS|jdtkr.dS|jdtkrEdSdS(NR%R&R8(R2R3R:R;(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR%,scC`s,|jddkrdS|jdr(dSdS(NR'R&R8(R2R3(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR'5s

(RBRCRHR(R%R'(((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyRb"s		tReportableChangescB`seZed��ZRS(cC`s2|jddkrdS|jddkr.dSdS(NR%R8R9R&R7(R2(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR%?s(RBRCRHR%(((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyRc>st
DifferencecB`sSeZdd�Zd�Zd�Zed��Zed��Zed��Z	RS(cC`s||_||_dS(N(twantthave(R4ReRf((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyt__init__Hs	cC`s9yt||�}|SWntk
r4|j|�SXdS(N(R]tAttributeErrort_Difference__default(R4tparamR>((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pytcompareLs

cC`sQt|j|�}y&t|j|�}||kr7|SWntk
rL|SXdS(N(R]ReRfRh(R4Rjtattr1tattr2((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyt	__defaultSs
cC`s&|jj|jjkr"|jjSdS(N(ReR#Rf(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR#\scC`s<|jjdkrdS|jj|jjkr8|jjSdS(N(ReR'R3Rf(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR'ascC`s<|jjdkrdS|jj|jjkr8|jjSdS(N(ReRKR3Rf(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyRKhsN(
RBRCR3RgRkRiRHR#R'RK(((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyRdGs			t
ModuleManagercB`s�eZd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Z	d�Z
d	�Zd
�Zd�Z
d�Zd
�Zd�Zd�Zd�Zd�ZRS(cO`sg|jdd�|_t|jj�|_t�|_td|jd|jj�|_	t
�|_dS(NtmoduleR@tparams(RWR3RpR
RqR@RIRfRJReRbtchanges(R4targstkwargs((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyRgqs
!cC`sji}xBtjD]7}t|j|�dk	rt|j|�||<qqW|rftd|�|_ndS(NRq(RRFR]ReR3RbRr(R4tchangedtkey((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyt_set_changed_optionsxscC`s�t|j|j�}tj}t�}xX|D]P}|j|�}|dkrUq.q.t|t�rt|j	|�q.|||<q.W|r�t
d|�|_tSt
S(NRq(RdReRfRREtdictRkR3t
isinstancetupdateRbRrR:R;(R4tdiffRERutktchange((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyt_update_changed_options�s		
cC`sK|jdg�}x2|D]*}|jjjd|dd|d�qWdS(Nt
__warningstmsgRA(tpopR@Rpt	deprecate(R4R>twarningstwarning((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyt_announce_deprecations�s


cC`s�t}t�}|jj}|dkr6|j�}n|dkrQ|j�}ntd|jj��}|j�}|j	|�|j
jr�|jr�|j
�|d<n|j	td|��|j|�|S(	NR6R&R8tabsentRqR{Ru(spresentsenabledsdisabled(R;RxReR)R6R�RcRrRaRzRpt_diffRft	make_diffR�(R4RuR>R)t
reportableRr((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pytexec_module�s	

cC`sRt�}tj}x9|D]1}t||�dk	rt||�||<qqW|S(N(RxRRER]R3(R4titemR>RER|((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyt
_grab_attr�s		
cC`s1td|j|j�d|j|j��}|S(Ntbeforetafter(RxR�RfRe(R4R>((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR��s-cC`s|j�}|rtStS(N(R~R:R;(R4R>((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyt
should_update�scC`s$|j�r|j�S|j�SdS(N(texistsRztcreate(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR6�s
cC`s%t}|j�r!|j�}n|S(N(R;R�tremove(R4Ru((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR��scC`s9|jjrtS|j�|j�r5td��ntS(Ns$Failed to delete the virtual address(Rpt
check_modeR:tremove_from_deviceR�R(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR��s
cC`sM|j�|jjdkr6|jjidd6�n|jjdkrb|jjitd6�n|jjdkr�|jjitd6�n|jj	dkr�t
|jjdd�r�|jjidd6�q�|jjid	d6�n|jjr|jjrtd
��n|j
jr#tS|j�|j�r=tStd��dS(Ns/Common/traffic-group-1R#R%R'ttypetipv4s255.255.255.255R!s'ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffffs?'arp' and 'spanning' cannot both be enabled on virtual address.s$Failed to create the virtual address(RwReR#R3RzR%R:R'R;R!RR(RRpR�tcreate_on_deviceR�(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR��s(

cC`s�|j�|_|jjdk	rK|jj|jjkrKtd��qKn|jjdk	r�|jj|jjkr�td��q�n|jj	r�|jj
r�td��n|j�s�tS|j
jr�tS|j�tS(Ns^The netmask cannot be changed. Delete and recreate the virtual address if you need to do this.s^The address cannot be changed. Delete and recreate the virtual address if you need to do this.s?'arp' and 'spanning' cannot both be enabled on virtual address.(tread_current_from_deviceRfReR!R3RR(RMRrR%R'R�R;RpR�R:tupdate_on_device(R4((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyRz�s$
cC`s�dj|jjd|jjdt|jj|jj��}|jjj|�}y|j	�}Wnt
k
rwtSX|jdks�d|kr�|ddkr�tSt
S(Ns/https://{0}:{1}/mgmt/tm/ltm/virtual-address/{2}RPRQi�RR(RLR@RURReR<RNRVRWRXRTR;RR:(R4RYRZR[((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR�s


+cC`s�dj|jjd|jjdt|jj|jj��}|jjj|�}y|j	�}Wn%t
k
r�}tt|���nXd|kr�|ddkr�d|kr�t|d��q�t|j
��ntd|�S(Ns/https://{0}:{1}/mgmt/tm/ltm/virtual-address/{2}RPRQRRi�tmessageRq(RLR@RURReR<RNRVRWRXRTRROtcontentRI(R4RYRZR[tex((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR�s

cC`s�|jj�}dj|jjd|jjdt|jj|jj��}|jj	j
|d|�}y|j�}Wn%tk
r�}t
t|���nXd|kr�|ddkr�d|kr�t
|d��q�t
|j��ndS(Ns/https://{0}:{1}/mgmt/tm/ltm/virtual-address/{2}RPRQRXRRi�R�(Rrt
api_paramsRLR@RURReR<RNRVtpatchRXRTRROR�(R4RqRYRZR[R�((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR�.s

cC`s
|jj�}|jj|d<|jj|d<|jj|d<dj|jjd|jjd�}|jj	j
|d|�}y|j�}Wn%tk
r�}t
t|���nXd|kr|ddkrd|kr�t
|d��qt
|j��n|d
S(NRNR<R(s,https://{0}:{1}/mgmt/tm/ltm/virtual-address/RPRQRXRRi�i�i�R�tselfLink(i�i�i�(RrR�ReRNR<R(RLR@RURVtpostRXRTRROR�(R4RqRYRZR[R�((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR�As"
cC`sjdj|jjd|jjdt|jj|jj��}|jjj|�}|j	dkrft
SdS(Ns/https://{0}:{1}/mgmt/tm/ltm/virtual-address/{2}RPRQi�(RLR@RURReR<RNRVtdeleteRR:(R4RYRZ((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR�Xs

(RBRCRgRwR~R�R�R�R�R�R6R�R�R�RzR�R�R�R�R�(((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyRops$																	tArgumentSpeccB`seZd�ZRS(c"C`szt|_tdtdddddddg�dt�d	t�d
t�dtdd
�dt�dtddddg�dtddddgddg�dt�dtdddtdgf�dt�dtdd�dtdddddd d!g�d"tdddgd#d$�d%tdd��}i|_|jjt�|jj|�dd	gg|_d"d%gg|_dS(&NR)tdefaultR6tchoicesR�R8R&RNR(R!RR�R5RRt	selectiveRR1R/R-taliasestadvertise_routeR#R<tCommontfallbacktF5_PARTITIONR*R'tboolR?R,R.RKtremoved_in_versiong�z�G�@R%(	R:tsupports_check_modeRxR	t
argument_specRzRtrequired_one_oftmutually_exclusive(R4R�((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyRgdsL										(RBRCRg(((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyR�csc	C`s�t�}td|jd|jd|jd|j�}y,td|�}|j�}|j|�Wn)t	k
r�}|j
dt|��nXdS(NR�R�R�R�RpR�(R�RR�R�R�R�RoR�t	exit_jsonRt	fail_jsonRO(tspecRptmmtresultsR�((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pytmain�s				t__main__N(0t
__future__RRRR�t
__metaclass__tANSIBLE_METADATAt
DOCUMENTATIONtEXAMPLEStRETURNtansible.module_utils.basicRR	t)ansible.module_utils.parsing.convert_boolR
Rtdistutils.versionRt%library.module_utils.network.f5.bigipR
t&library.module_utils.network.f5.commonRRRRRt)library.module_utils.network.f5.ipaddressRRt(library.module_utils.network.f5.icontrolRtImportErrort%ansible.module_utils.network.f5.bigipt&ansible.module_utils.network.f5.commont)ansible.module_utils.network.f5.ipaddresst(ansible.module_utils.network.f5.icontrolRRIRJR\RbRctobjectRdRoR�R�RB(((sT/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_virtual_address.pyt<module>sX


�0
�A	)�;	

Anons79 File Manager Version 1.0, Coded By Anons79
Email: [email protected]