Server IP : 80.87.202.40 / Your IP : 216.73.216.169 Web Server : Apache System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64 User : bitrix ( 600) PHP Version : 8.2.27 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /lib/python3.11/site-packages/ansible/inventory/__pycache__/ |
Upload File : |
� ���c2s � � � d dl mZmZmZ eZd dlZd dlZd dlZd dl Z d dl Z d dlZd dlm Z d dlmZ d dlmZ d dlmZmZmZ d dlmZ d dlmZ d d lmZmZ d d lmZ d dl m!Z! d dl"m#Z# d d l$m%Z% d dl&m'Z' d dl(m)Z) d dl*m+Z+ e'� � Z,g d�Z-d� ej. D � � Z/d� ej0 D � � Z1 e j2 d�3 e-e/z e1z � � � � Z4 e j2 de j5 � � Z6d� Z7d� Z8 G d� de9� � Z:dS )� )�absolute_import�division�print_functionN)� attrgetter)�shuffle)� constants)�AnsibleError�AnsibleOptionsError�AnsibleParserError)� InventoryData)�string_types)�to_bytes�to_text)� parse_address)�inventory_loader)�deduplicate_list)�unfrackpath)�Display)�combine_vars)�get_vars_from_inventory_sources)s ^\.s ^host_vars$s ^group_vars$s ^vars_plugins$c �, � g | ]}t |� � ��S � )r ��.0�xs �>/usr/lib/python3.11/site-packages/ansible/inventory/manager.py� <listcomp>r 0 s � �E�E�E�A�H�Q�K�K�E�E�E� c �V � g | ]&}d t t j |� � � � z ��'S )s %s$)r �re�escaper s r r r 1 s- � �Q�Q�Q�A���"�)�A�,�,�/�/�/�Q�Q�Qr � |a> ^ (.+) # A pattern expression ending with... \[(?: # A [subscript] expression comprising: (-?[0-9]+)| # A single positive or negative number ([0-9]+)([:-]) # Or an x:y or x: range. ([0-9]*) )\] $ c �� � g }g }g }| D ]^}|s�|d dk r|� |� � �'|d dk r|� |� � �I|� |� � �_|g k rdg}||z |z S )zS takes a list of patterns and reorders them by modifier to apply them consistently r �!�&�all)�append)�patterns�pattern_regular�pattern_intersection�pattern_exclude�ps r �order_patternsr- B s� � � �O����O� � &� &��� ���Q�4�3�;�;��"�"�1�%�%�%�%� �q�T�S�[�[� �'�'��*�*�*�*��"�"�1�%�%�%�%� �"��� �'�� �1�1�O�C�Cr c �� � t | t � � r8d� | D � � }t t j � |� � � � S t | t � � st | d�� � } d| v r| � d� � }nV t | d�� � \ }}| g}n=# t $ r0 t j t d� � | t j � � }Y nw xY wd� |D � � S ) a� Takes a string containing host patterns separated by commas (or a list thereof) and returns a list of single patterns (which may not contain commas). Whitespace is ignored. Also accepts ':' as a separator for backwards compatibility, but it is not recommended due to the conflict with IPv6 addresses and host ranges. Example: 'a,b[1], c[2:3] , d' -> ['a', 'b[1]', 'c[2:3]', 'd'] c 3 �4 K � | ]}t |� � V � �d S �N)�split_host_pattern�r r, s r � <genexpr>z%split_host_pattern.<locals>.<genexpr>k s+ � � � �:�:�Q�%�a�(�(�:�:�:�:�:�:r �surrogate_or_strict��errors�,T)�allow_rangesaJ (?: # We want to match something comprising: [^\s:\[\]] # (anything other than whitespace or ':[]' | # ...or... \[[^\]]*\] # a single complete bracketed expression) )+ # occurring once or more c �^ � g | ]*}|� � � �|� � � ��+S r )�stripr2 s r r z&split_host_pattern.<locals>.<listcomp>� s- � �5�5�5�!�1�7�7�9�9�5�A�G�G�I�I�5�5�5r ) � isinstance�list� itertools�chain� from_iterabler r �splitr � Exceptionr �findall�X)�pattern�resultsr( �base�ports r r1 r1 ^ s � � �'�4� � � A�:�:�'�:�:�:���I�O�1�1�'�:�:�;�;�;� ��� .� .� A��'�*?�@�@�@�� �w����=�=��&�&��� �(��t�D�D�D�L�T�4��y�H�H��� � � � �z�� � � � �r�t� � �H�H�H� ���� 6�5�x�5�5�5�5s �B'