Dashboard
PHP:
8.2.30
OS:
Linux
User:
dh_nv8b2m
/
/
usr
/
local
/
lib
/
python3.10
/
dist-packages
/
ansible
/
cli
/
__pycache__
📤 Upload
📝 New File
📁 New Folder
Close
Editing: pull.cpython-310.pyc
o O�h�C � @ s� d dl mZ d dlmZ d dlZd dlZd dlZd dlZd dlZd dl Z d dl Z d dlZd dlZd dl mZ d dl mZ d dlmZ d dlmZ d dlmZmZ d d lmZ d d lmZ d dlmZ e� ZG dd � d e�Z ddd�Z!e"dkr{e!� dS dS )� )�annotations)�CLIN)� constants)�context)�option_helpers)�AnsibleOptionsError)� to_native�to_text)� module_loader)�run_cmd)�Displayc s� e Zd ZdZdZdZdZdZddd�Zd d iZ dZ edd � �Z� fdd�Z � fdd�Z� fdd�Zedd� �Zedd� �Z� ZS )�PullCLIaO Used to pull a remote copy of ansible on each managed node, each set to run via cron and update playbook source via a source repository. This inverts the default *push* architecture of ansible into a *pull* architecture, which has near-limitless scaling potential. None of the CLI tools are designed to run concurrently with themselves, you should use an external scheduler and/or locking to ensure there are no clashing operations. The setup playbook can be tuned to change the cron frequency, logging locations, and parameters to ansible-pull. This is useful both for extreme scale-out as well as periodic remediation. Usage of the 'fetch' module to retrieve logs from ansible-pull runs would be an excellent way to gather and analyze remote logs from ansible-pull. zansible-pull�gitz local.yml)r � subversion�hg�bzrzFile does not existzFile is not readable)� � �playbook.ymla The name of one the YAML format files to run as an Ansible playbook. This can be a relative path within the checkout. By default, Ansible will look for a playbook based on the host's fully-qualified domain name, on the host hostname and finally a playbook named *local.yml*.Tc C sd d} t j�dd�r0t jd D ]!}t|t�r| dd�|� 7 } qd|v s)tj�|�r/| d| 7 } q| S )N� � inventoryFz -i '%s' �,z -i %s ) r �CLIARGS�get� isinstance�list�join�os�path�exists)�inv_opts�inv� r"