Anons79 Mini Shell

Directory : /lib/python2.7/site-packages/ansible/modules/web_infrastructure/ansible_tower/
Upload File :
Current File : //lib/python2.7/site-packages/ansible/modules/web_infrastructure/ansible_tower/tower_host.pyo

�
�Udac@`s�ddlmZmZmZeZidd6dgd6dd6ZdZd	Zdd
l	Z	ddl
mZmZm
Z
mZy/dd
lZdd
ljZddlmZWnek
r�nXd
�Zedkr�e�nd
S(i(tabsolute_importtdivisiontprint_functions1.1tmetadata_versiontpreviewtstatust	communitytsupported_bys�
---
module: tower_host
version_added: "2.3"
author: "Wayne Witzel III (@wwitzel3)"
short_description: create, update, or destroy Ansible Tower host.
description:
    - Create, update, or destroy Ansible Tower hosts. See
      U(https://www.ansible.com/tower) for an overview.
options:
    name:
      description:
        - The name to use for the host.
      required: True
    description:
      description:
        - The description to use for the host.
    inventory:
      description:
        - Inventory the host should be made a member of.
      required: True
    enabled:
      description:
        - If the host should be enabled.
      type: bool
      default: 'yes'
    variables:
      description:
        - Variables to use for the host. Use C(@) for a file.
    state:
      description:
        - Desired state of the resource.
      choices: ["present", "absent"]
      default: "present"
extends_documentation_fragment: tower
s�
- name: Add tower host
  tower_host:
    name: localhost
    description: "Local Host Group"
    inventory: "Local Inventory"
    state: present
    tower_config_file: "~/tower_cli.cfg"
    variables:
      example_var: 123
N(tTowerModulettower_auth_configttower_check_modet
HAS_TOWER_CLI(tsettingscC`s�tdtdt�dt�dtdt�dtdddt�d	t�d
tddd
gdd��}td|dt�}|jjd�}|jjd�}|jjd�}|jjd�}|jjd
�}|jjd	�}|r?|jd�r?tjj|d�}t	|d��}	|	j
�}WdQXq?ni|d6|d
6}
t|�}tj
|��:t|�tjd�}y�tjd�}
|
jd|�}|dkr�|jd|d|dd|d	|d|dt�}|d|
d<n+|d
kr(|jd|d|d�}nWnxtjk
r`}|jddj|�dt�nDtjtjtjfk
r�}|jddj|�dt�nXWdQX|d|
d<|j|
�dS(Ntnametrequiredtdescriptiont	inventorytenabledttypetbooltdefaultt	variableststatetchoicestpresenttabsentt
argument_spectsupports_check_modet@itrthosttidtcreate_on_missingtmsgs/Failed to update host, inventory not found: {0}tchangedsFailed to update host: {0}(tdicttTrueRtparamstgett
startswithtostpatht
expandusertopentreadR	Rtruntime_valuesR
t	tower_clitget_resourcetmodifytdeletetexctNotFoundt	fail_jsontformattFalsetConnectionErrort
BadRequestt	AuthErrort	exit_json(RtmoduleR
RRRRRtfilenametftjson_outputt
tower_authRtinv_restinvtresulttexcinfo((s_/usr/lib/python2.7/site-packages/ansible/modules/web_infrastructure/ansible_tower/tower_host.pytmainPsN		
#"!)t__main__(t
__future__RRRRt
__metaclass__tANSIBLE_METADATAt
DOCUMENTATIONtEXAMPLESR(t"ansible.module_utils.ansible_towerRR	R
RR.ttower_cli.exceptionst
exceptionsR2ttower_cli.confRtImportErrorRDt__name__(((s_/usr/lib/python2.7/site-packages/ansible/modules/web_infrastructure/ansible_tower/tower_host.pyt<module>s"


&
"
	2

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